Update selector for folder location updates in renderer.js
This commit is contained in:
@@ -525,11 +525,11 @@ folders.forEach(folderObj => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
window.electronAPI.onFoldersLocationUpdated(folderObj => {
|
window.electronAPI.onFoldersLocationUpdated(folderObj => {
|
||||||
const selector = `[data-folder-path="${folderObj.path.replace(/"/g, '\\"')}"]`;
|
const selector = `[data-folder-id="${encodeURIComponent(folderObj.path)}"]`;
|
||||||
const li = document.querySelector(selector);
|
const li = document.querySelector(selector);
|
||||||
if (li) {
|
if (li) {
|
||||||
li.classList.toggle('needs-relocation', folderObj.needsRelocation);
|
li.classList.toggle('needs-relocation', folderObj.needsRelocation);
|
||||||
// evtl. noch ein !-Icon sichtbar machen
|
// etc.
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
Reference in New Issue
Block a user