mirror of
https://github.com/zadam/trilium.git
synced 2025-11-01 02:45:54 +01:00
added isBeingDeleted to be able to recognize that note is being deleted while still leaving it accessible
This commit is contained in:
@@ -72,6 +72,8 @@ class Note extends AbstractEntity {
|
||||
this.utcDateCreated = utcDateCreated || dateUtils.utcNowDateTime();
|
||||
/** @type {string} */
|
||||
this.utcDateModified = utcDateModified;
|
||||
/** @type {boolean} - set during the deletion operation, before it is completed (removed from becca completely) */
|
||||
this.isBeingDeleted = false;
|
||||
|
||||
// ------ Derived attributes ------
|
||||
|
||||
@@ -1327,7 +1329,7 @@ class Note extends AbstractEntity {
|
||||
}
|
||||
|
||||
get isDeleted() {
|
||||
return !(this.noteId in this.becca.notes);
|
||||
return !(this.noteId in this.becca.notes) || this.isBeingDeleted;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user