From 74c53b9040669ad26604c42ec4c91ebd78e08439 Mon Sep 17 00:00:00 2001 From: Shin'ya Ueoka Date: Tue, 17 Oct 2017 22:01:01 +0900 Subject: fix settings reload --- src/content/components/common/index.js | 2 +- src/shared/messages.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/content/components/common/index.js b/src/content/components/common/index.js index a05febd..5e977ae 100644 --- a/src/content/components/common/index.js +++ b/src/content/components/common/index.js @@ -28,7 +28,7 @@ export default class Common { } onMessage(message, sender) { - switch (message) { + switch (message.type) { case messages.SETTINGS_CHANGED: this.reloadSettings(); } diff --git a/src/shared/messages.js b/src/shared/messages.js index 581e167..134d71c 100644 --- a/src/shared/messages.js +++ b/src/shared/messages.js @@ -1,6 +1,4 @@ export default { - SETTINGS_QUERY: 'settings.query', - BACKGROUND_OPERATION: 'background.operation', CONSOLE_BLURRED: 'console.blured', @@ -23,4 +21,6 @@ export default { OPEN_URL: 'open.url', SETTINGS_RELOAD: 'settings.reload', + SETTINGS_CHANGED: 'settings.changed', + SETTINGS_QUERY: 'settings.query', }; -- cgit v1.2.3