Emergency fix

This commit is contained in:
CyTube 2014-02-28 06:47:06 +01:00
parent 0dfb6df8a7
commit 97f682a022

View file

@ -1814,19 +1814,19 @@ Channel.prototype.handleQueuePlaylist = function (user, data) {
} }
} }
for (var i = 0; i < pl.length; i++) { pl.forEach(function (pli) {
pl[i].pos = pos; pli.pos = pos;
pl[i].temp = temp; pli.temp = temp;
pl[i].queueby = user.name; pli.queueby = user.name;
self.addMedia(pl[i], function (err, media) { self.addMedia(pli, function (err, media) {
if (err) { if (err) {
user.socket.emit("queueFail", { user.socket.emit("queueFail", {
msg: err, msg: err,
link: util.formatLink(pl[i].id, pl[i].type) link: util.formatLink(pli.id, pli.type)
}); });
} }
}); });
} });
} catch (e) { } catch (e) {
Logger.errlog.log("Loading user playlist failed!"); Logger.errlog.log("Loading user playlist failed!");
Logger.errlog.log("PL: " + user.name + "-" + name); Logger.errlog.log("PL: " + user.name + "-" + name);