diff options
Diffstat (limited to 'ext/js/pages/settings/permissions-origin-controller.js')
-rw-r--r-- | ext/js/pages/settings/permissions-origin-controller.js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ext/js/pages/settings/permissions-origin-controller.js b/ext/js/pages/settings/permissions-origin-controller.js index a0f23af6..9447e3cc 100644 --- a/ext/js/pages/settings/permissions-origin-controller.js +++ b/ext/js/pages/settings/permissions-origin-controller.js @@ -18,6 +18,7 @@ import {EventListenerCollection} from '../../core/event-listener-collection.js'; import {toError} from '../../core/to-error.js'; +import {getAllPermissions, setPermissionsGranted} from '../../data/permissions-util.js'; import {querySelectorNotNull} from '../../dom/query-selector.js'; export class PermissionsOriginController { @@ -140,7 +141,7 @@ export class PermissionsOriginController { /** */ async _updatePermissions() { - const permissions = await this._settingsController.permissionsUtil.getAllPermissions(); + const permissions = await getAllPermissions(); this._onPermissionsChanged({permissions}); } @@ -152,7 +153,7 @@ export class PermissionsOriginController { async _setOriginPermissionEnabled(origin, enabled) { let added = false; try { - added = await this._settingsController.permissionsUtil.setPermissionsGranted({origins: [origin]}, enabled); + added = await setPermissionsGranted({origins: [origin]}, enabled); } catch (e) { const errorContainer = /** @type {HTMLElement} */ (this._errorContainer); errorContainer.hidden = false; |