mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
add API method to erase a revision #4662
This commit is contained in:
parent
9565b0b43d
commit
0ad337c8e8
@ -161,6 +161,13 @@ class BRevision extends AbstractBeccaEntity {
|
||||
return this.getAttachments().filter(attachment => attachment.title === title)[0];
|
||||
}
|
||||
|
||||
/**
|
||||
* Revisions are not soft-deletable, they are immediately hard-deleted (erased).
|
||||
*/
|
||||
eraseRevision() {
|
||||
require("../../services/erase.js").eraseRevisions([this.revisionId]);
|
||||
}
|
||||
|
||||
beforeSaving() {
|
||||
super.beforeSaving();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user