mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-21 22:19:41 +01:00
feat: publish event when deleting empty note
This commit is contained in:
@@ -37,7 +37,10 @@ export default class Notes extends Collection {
|
|||||||
};
|
};
|
||||||
|
|
||||||
if (isNoteEmpty(note)) {
|
if (isNoteEmpty(note)) {
|
||||||
if (oldNote) await this.remove(id);
|
if (oldNote) {
|
||||||
|
this._db.ev.publish("notes:removeEmptyNote", id);
|
||||||
|
await this.remove(id);
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user