fix(snjs): showing archived notes on trashed smart view (#1426)

This commit is contained in:
Karol Sójko
2022-08-24 12:45:13 +02:00
committed by GitHub
parent 26fe530deb
commit 2c69a514a8
2 changed files with 39 additions and 4 deletions

View File

@@ -127,20 +127,20 @@ export class ItemManager
const override: Models.FilterDisplayOptions = {}
if (options.views && options.views.find((view) => view.uuid === Models.SystemViewId.AllNotes)) {
if (options.includeArchived == undefined) {
if (options.includeArchived === undefined) {
override.includeArchived = false
}
if (options.includeTrashed == undefined) {
if (options.includeTrashed === undefined) {
override.includeTrashed = false
}
}
if (options.views && options.views.find((view) => view.uuid === Models.SystemViewId.ArchivedNotes)) {
if (options.includeTrashed == undefined) {
if (options.includeTrashed === undefined) {
override.includeTrashed = false
}
}
if (options.views && options.views.find((view) => view.uuid === Models.SystemViewId.TrashedNotes)) {
if (options.includeArchived == undefined) {
if (!options.includeArchived) {
override.includeArchived = true
}
}