Skip to content
Snippets Groups Projects
Commit 6c4e3a50 authored by Roger Braun's avatar Roger Braun
Browse files

Don't display if we don't have a chat.

parent a03b92e2
Branches
No related tags found
No related merge requests found
......@@ -7,7 +7,7 @@
</div>
<div class="panel-body base01-background">
<div class="chat-window">
<div class="chat-message" v-for="message in messages">
<div class="chat-message" v-for="message in messages" :key="message.id">
<span class="chat-avatar">
<img :src="message.author.avatar" />
{{message.author.username}}:
......
......@@ -2,6 +2,9 @@ const NavPanel = {
computed: {
currentUser () {
return this.$store.state.users.currentUser
},
chat () {
return this.$store.state.chat.channel
}
}
}
......
......@@ -7,7 +7,7 @@
{{ $t("nav.timeline") }}
</router-link>
</li>
<li v-if='currentUser'>
<li v-if='chat && currentUser'>
<router-link class="base00-background" to='/chat'>
{{ $t("nav.chat") }}
</router-link>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment