From d0328f8da0fdacedda5db14e9b6753802495a815 Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Tue, 27 Mar 2018 18:48:26 +0200 Subject: [PATCH] [lib.channel-controller] fix nav() update channel.id before room.fetch() for rooms to be fetched according to the NEW channel id --- webpack/lib/channel-controller.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/webpack/lib/channel-controller.js b/webpack/lib/channel-controller.js index dcc2b67..4c8171b 100644 --- a/webpack/lib/channel-controller.js +++ b/webpack/lib/channel-controller.js @@ -37,12 +37,12 @@ export default class ChannelController{ /* (2) Navigate vue-router */ gs.get.router.push(`/channel/${channel.link}`); - /* (3) Load rooms */ - gs.get.room.fetch(); - - /* (4) Update active element */ + /* (3) Update active element */ this.current = channel.id; + /* (4) Load rooms */ + gs.get.room.fetch(); + /* (5) Log channel */ console.log(`[channel.current] ${channel.link} (${channel.label})`);