summaryrefslogtreecommitdiff
path: root/ext/js/pages/settings/settings-controller.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/js/pages/settings/settings-controller.js')
-rw-r--r--ext/js/pages/settings/settings-controller.js11
1 files changed, 2 insertions, 9 deletions
diff --git a/ext/js/pages/settings/settings-controller.js b/ext/js/pages/settings/settings-controller.js
index 25f5e8ad..49fa9c9e 100644
--- a/ext/js/pages/settings/settings-controller.js
+++ b/ext/js/pages/settings/settings-controller.js
@@ -20,7 +20,7 @@ import {EventDispatcher} from '../../core/event-dispatcher.js';
import {EventListenerCollection} from '../../core/event-listener-collection.js';
import {generateId, isObject} from '../../core/utilities.js';
import {OptionsUtil} from '../../data/options-util.js';
-import {PermissionsUtil} from '../../data/permissions-util.js';
+import {getAllPermissions} from '../../data/permissions-util.js';
import {HtmlTemplateCollection} from '../../dom/html-template-collection.js';
import {yomitan} from '../../yomitan.js';
@@ -41,8 +41,6 @@ export class SettingsController extends EventDispatcher {
/** @type {HtmlTemplateCollection} */
this._templates = new HtmlTemplateCollection();
this._templates.load(document);
- /** @type {PermissionsUtil} */
- this._permissionsUtil = new PermissionsUtil();
}
/** @type {string} */
@@ -60,11 +58,6 @@ export class SettingsController extends EventDispatcher {
this._setProfileIndex(value, true);
}
- /** @type {PermissionsUtil} */
- get permissionsUtil() {
- return this._permissionsUtil;
- }
-
/** */
async prepare() {
yomitan.on('optionsUpdated', this._onOptionsUpdated.bind(this));
@@ -338,7 +331,7 @@ export class SettingsController extends EventDispatcher {
const eventName = 'permissionsChanged';
if (!this.hasListeners(eventName)) { return; }
- const permissions = await this._permissionsUtil.getAllPermissions();
+ const permissions = await getAllPermissions();
this.trigger(eventName, {permissions});
}