소스 검색

Use cleaner instance config check for shoutbox setting

Eris 3 년 전
부모
커밋
7e3393b5a2
2개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      src/components/settings_modal/tabs/general_tab.js
  2. 1 1
      src/components/settings_modal/tabs/general_tab.vue

+ 1 - 1
src/components/settings_modal/tabs/general_tab.js

@@ -50,7 +50,7 @@ const GeneralTab = {
       return this.$store.state.instance.background &&
         !this.$store.state.users.currentUser.background_image
     },
-    shout () { return this.$store.state.shout.channel.state === 'joined' },
+    instanceShoutboxPresent () { return this.$store.state.instance.shoutAvailable },
     ...SharedComputedObject()
   }
 }

+ 1 - 1
src/components/settings_modal/tabs/general_tab.vue

@@ -21,7 +21,7 @@
             {{ $t('settings.hide_wallpaper') }}
           </BooleanSetting>
         </li>
-        <li v-if="shout">
+        <li v-if="instanceShoutboxPresent">
           <BooleanSetting path="hideShoutbox">
             {{ $t('general.hide') }} {{ $t('shoutbox.title') }}
           </BooleanSetting>