Add the ability to register external images into the module using the ImageApp

This commit is contained in:
Oliver 2026-02-07 18:29:20 -07:00
parent 16e61a4855
commit 3fdbdf842c
5 changed files with 144 additions and 43 deletions

View file

@ -43,15 +43,17 @@ export function DBConnectorMixin(HandlebarsApp) {
return super.render(options, ...args);
};
async _fetchDocument() {
async _fetchDocument(silent = false) {
if (!this._docID) { return }
const documents = await getFile(this.dbPath);
if (documents[this._docID] == null) {
ui.notifications.error(_loc(
`IT.notifs.error.document-ID-404`,
{ id: this._docID, dbType: this.dbType },
));
if (!silent) {
ui.notifications.error(_loc(
`IT.notifs.error.document-ID-404`,
{ id: this._docID, dbType: this.dbType },
));
}
return false;
};