fix(collections): displaying note list even if session is not unlocked

This commit is contained in:
Elian Doran 2026-03-12 20:53:19 +02:00
parent 744b93dd98
commit 9e99670b19
No known key found for this signature in database

View File

@ -381,6 +381,10 @@ class NoteContext extends Component implements EventListener<"entitiesReloaded">
// Collections must always display a note list, even if no children.
if (note.type === "book") {
if (note.isProtected && !protectedSessionHolder.isProtectedSessionAvailable()) {
return false;
}
const viewType = note.getLabelValue("viewType") ?? "grid";
if (!["list", "grid"].includes(viewType)) {
return true;