aboutsummaryrefslogtreecommitdiff
path: root/ext/js/pages/settings/recommended-permissions-controller.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/js/pages/settings/recommended-permissions-controller.js')
-rw-r--r--ext/js/pages/settings/recommended-permissions-controller.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/js/pages/settings/recommended-permissions-controller.js b/ext/js/pages/settings/recommended-permissions-controller.js
index a870de50..0500759e 100644
--- a/ext/js/pages/settings/recommended-permissions-controller.js
+++ b/ext/js/pages/settings/recommended-permissions-controller.js
@@ -17,6 +17,7 @@
*/
import {EventListenerCollection} from '../../core.js';
+import {toError} from '../../core/to-error.js';
export class RecommendedPermissionsController {
/**
@@ -92,7 +93,7 @@ export class RecommendedPermissionsController {
} catch (e) {
if (this._errorContainer !== null) {
this._errorContainer.hidden = false;
- this._errorContainer.textContent = e instanceof Error ? e.message : `${e}`;
+ this._errorContainer.textContent = toError(e).message;
}
}
if (!added) { return false; }