Fix voteskips

This commit is contained in:
Calvin Montgomery 2013-07-05 23:34:04 -04:00
parent ee1b6c3255
commit 6a9c9f9235
2 changed files with 6 additions and 0 deletions

View file

@ -977,6 +977,11 @@ Channel.prototype.broadcastDrinks = function() {
/* REGION Playlist Stuff */
Channel.prototype.onVideoChange = function () {
this.voteskip = false;
this.broadcastVoteskipUpdate();
}
// The server autolead function
function mediaUpdate(chan, id) {
// Bail cases - video changed, someone's leader, no video playing

View file

@ -42,6 +42,7 @@ function Playlist(chan) {
chan.sendAll("mediaUpdate", m.timeupdate());
});
this.on("changeMedia", function(m) {
chan.onVideoChange();
chan.sendAll("setCurrent", pl.current.uid);
chan.sendAll("changeMedia", m.fullupdate());
});