Tagged downstream network errors to respect networkWarningStyle setting

This commit is contained in:
A-wry
2026-02-23 22:10:25 -05:00
parent f4d8c0a8db
commit fdcf3be0f9
5 changed files with 35 additions and 19 deletions

View File

@@ -237,7 +237,7 @@ export class ModuleObsidianAPI extends AbstractObsidianModule {
} catch (ex: any) {
this._log(`HTTP:${method}${size} to:${localURL} -> failed`, LOG_LEVEL_VERBOSE);
const msg = ex instanceof Error ? `${ex?.name}:${ex?.message}` : ex?.toString();
this.showError(`Failed to fetch: ${msg}`); // Do not show notice, due to throwing below
this.showError(`\u{200b}Network Error: Failed to fetch: ${msg}`); // Do not show notice, due to throwing below
this._log(ex, LOG_LEVEL_VERBOSE);
// limit only in bulk_docs.
if (url.toString().indexOf("_bulk_docs") !== -1) {