Log when a video is added

This commit is contained in:
Calvin Montgomery 2015-01-03 16:03:15 -05:00
parent 829cc090fa
commit bf70d2760b
1 changed files with 4 additions and 1 deletions

View File

@ -627,7 +627,7 @@ PlaylistModule.prototype.handleJumpTo = function (user, data) {
var old = this.current; var old = this.current;
this.current = to; this.current = to;
this.startPlayback(); this.startPlayback();
this.channel.logger.log("[playlist] " + user.getName() + " skipped" + title); this.channel.logger.log("[playlist] " + user.getName() + " skipped " + title);
if (old && old.temp) { if (old && old.temp) {
this._delete(old.uid); this._delete(old.uid);
@ -937,6 +937,9 @@ PlaylistModule.prototype._addItem = function (media, data, user, cb) {
self.meta.count++; self.meta.count++;
self.meta.rawTime += media.seconds; self.meta.rawTime += media.seconds;
self.meta.time = util.formatTime(self.meta.rawTime); self.meta.time = util.formatTime(self.meta.rawTime);
var m = item.media;
self.channel.logger.log("[playlist] " + (data.queueby || "(anonymous)") +
" added " + m.title + " (" + m.type + ":" + m.id + ")");
var perms = self.channel.modules.permissions; var perms = self.channel.modules.permissions;
self.channel.users.forEach(function (u) { self.channel.users.forEach(function (u) {