From a7cbdbc1f28873901b095336fc80e68fa13a2748 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sun, 22 Apr 2018 17:43:02 +0900 Subject: [PATCH] :v: --- src/client/app/init.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/client/app/init.ts b/src/client/app/init.ts index 2f79e6cab1..26f5328d7d 100644 --- a/src/client/app/init.ts +++ b/src/client/app/init.ts @@ -82,12 +82,12 @@ Vue.mixin({ methods: { _updateDarkmode_(v) { localStorage.setItem('darkmode', v.toString()); - bus.$emit('updated', v); if (v) { document.documentElement.setAttribute('data-darkmode', 'true'); } else { document.documentElement.removeAttribute('data-darkmode'); } + bus.$emit('updated', v); }, _onDarkmodeUpdated_(v) { if (!this.$el || !this.$el.setAttribute) return;