Skip to content

ResourceLockComponent.requestUnlockForPath method

ResourceLockComponent › requestUnlockForPath

Fully unlocks the note at the given path: resolves the lock covering it (the path itself when directly locked, otherwise a subtree-locked ancestor folder), cancels the operation(s) that took the lock by aborting their AbortControllers, and releases the lock so the note becomes editable — regardless of which plugin holds the lock. Powers the "Unlock active note" command. A no-op when nothing covers the path.

Signature:

requestUnlockForPath(pathOrFile: PathOrFile): void

Parameters:

ParameterTypeDescription
pathOrFilePathOrFileThe path or file of the note to unlock.

Returns: void