diff --git a/client/pages/config/sessions.vue b/client/pages/config/sessions.vue index e6925c69..0b74955c 100644 --- a/client/pages/config/sessions.vue +++ b/client/pages/config/sessions.vue @@ -53,8 +53,10 @@
{{ $strings.MessageNoListeningSessions }}
+ + -Open Listening Sessions
+Open Listening Sessions
- {{ filteredUserUsername }} -{{ session.user ? session.user.username : 'N/A' }} +{{ session.user ? session.user.username : 'N/A' }} |
{{ getPlayMethodName(session.playMethod) }} @@ -153,8 +154,8 @@ export default { }, filteredUserUsername() { if (!this.userFilter) return null - var user = this.users.find((u) => u.id === this.userFilter) - return user ? user.username : null + const user = this.users.find((u) => u.id === this.userFilter) + return user?.username || null }, dateFormat() { return this.$store.state.serverSettings.dateFormat @@ -273,7 +274,7 @@ export default { return 'Unknown' }, async loadSessions(page) { - var userFilterQuery = this.selectedUser ? `&user=${this.selectedUser}` : '' + const userFilterQuery = this.selectedUser ? `&user=${this.selectedUser}` : '' const data = await this.$axios.$get(`/api/sessions?page=${page}&itemsPerPage=${this.itemsPerPage}${userFilterQuery}`).catch((err) => { console.error('Failed to load listening sessions', err) return null |