1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-23 22:36:32 +02:00

Web: Fixes #13153: Fix installing certain plugins (#13154)

This commit is contained in:
Henry Heino
2025-09-08 16:30:48 -07:00
committed by GitHub
parent 7777f8428f
commit 1762f9485f

View File

@@ -236,15 +236,20 @@ export class WorkerApi {
const folderName = removeReservedWords(basename(path));
let handle: FileSystemDirectoryHandle;
try {
handle = await parent.getDirectoryHandle(folderName, { create });
this.directoryHandleCache_.set(path, handle);
} catch (error) {
if (!isNotFoundError(error)) {
throw error;
}
if (!parent) {
logger.debug('Parent not found for path', path);
handle = null;
} else {
try {
handle = await parent.getDirectoryHandle(folderName, { create });
this.directoryHandleCache_.set(path, handle);
} catch (error) {
if (!isNotFoundError(error)) {
throw error;
}
handle = null;
}
}
return handle;