From ba91f8bde5474bbf97cec0cc62663195e3b948a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kasper=20Rynning-T=C3=B8nnesen?= Date: Wed, 10 Jun 2015 18:45:17 +0200 Subject: [PATCH] Forgot something in remote --- static/js/hostcontroller.js | 2 +- static/js/list.js | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/static/js/hostcontroller.js b/static/js/hostcontroller.js index 32c65087..dd7d95fc 100755 --- a/static/js/hostcontroller.js +++ b/static/js/hostcontroller.js @@ -27,7 +27,7 @@ socket.on("id", function(id) chan = arr[1].toLowerCase(); $("#chan").html(chan.substring(0,1).toUpperCase()+chan.substring(1).toLowerCase()); socket.on(chan.toLowerCase(), function(msg){ - populate_list(msg, false); + channel_function(msg); }); setup_youtube_listener(chan); diff --git a/static/js/list.js b/static/js/list.js index 162cff23..a6a89551 100755 --- a/static/js/list.js +++ b/static/js/list.js @@ -16,6 +16,11 @@ var check = false; return check; }; socket.on(chan.toLowerCase(), function(msg){ + channel_function(msg); +}); + +function channel_function(msg) +{ if(msg[0] == "list") { full_playlist = msg[1]; @@ -58,7 +63,7 @@ socket.on(chan.toLowerCase(), function(msg){ populate_list(full_playlist); } -}); +} socket.on("skipping", function(obj) {