(folder, sourceId = '')
| 186 | } |
| 187 | |
| 188 | function setLastOpenedFolder(folder, sourceId = '') { |
| 189 | const f = String(folder || '').trim(); |
| 190 | if (!f) return; |
| 191 | const key = getLastOpenedFolderKey(sourceId); |
| 192 | try { localStorage.setItem(key, f); } catch (e) { /* ignore */ } |
| 193 | if (key !== 'lastOpenedFolder') { |
| 194 | try { localStorage.setItem('lastOpenedFolder', f); } catch (e) { /* ignore */ } |
| 195 | } |
| 196 | } |
| 197 | |
| 198 | function getSourceNameById(sourceId) { |
| 199 | const id = String(sourceId || '').trim(); |
no test coverage detected