Support \noinferiors to disallow creating subfolders

This commit is contained in:
the-djmaze 2023-11-22 04:07:57 +01:00
parent d74407f36b
commit 5cdbba8da0
3 changed files with 8 additions and 12 deletions

View file

@ -29,10 +29,8 @@ export class FolderCreatePopupView extends AbstractViewPopup {
[],
[['', '']],
oItem => oItem ? oItem.detailedName() : '',
FolderUserStore.namespace
? item => !item.fullName.startsWith(FolderUserStore.namespace)
: null,
true
item => !item.subFolders.allow
|| (FolderUserStore.namespace && !item.fullName.startsWith(FolderUserStore.namespace))
)
);