mirror of https://github.com/calzoneman/sync.git
Minor fix
This commit is contained in:
parent
b6a1dd8cb3
commit
c213eb2f31
|
@ -52,6 +52,10 @@ MediaRefresherModule.prototype.initVimeo = function (data, cb) {
|
|||
var self = this;
|
||||
self.channel.activeLock.lock();
|
||||
InfoGetter.vimeoWorkaround(data.id, function (hack) {
|
||||
if (self.dead || self.channel.dead) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (self._media === data) {
|
||||
self.channel.logger.log("[mediarefresher] Refreshed vimeo video with ID " +
|
||||
data.id);
|
||||
|
@ -72,15 +76,23 @@ MediaRefresherModule.prototype.refreshGoogleDocs = function (media, cb) {
|
|||
|
||||
self.channel.activeLock.lock();
|
||||
InfoGetter.getMedia(media.id, "gd", function (err, data) {
|
||||
if (self.dead || self.channel.dead) {
|
||||
return;
|
||||
}
|
||||
|
||||
switch (err) {
|
||||
case "HTTP 302":
|
||||
case "Video not found":
|
||||
case "Private video":
|
||||
self.channel.logger.log("[mediarefresher] Google Docs refresh failed: " +
|
||||
err);
|
||||
self.channel.activeLock.release();
|
||||
if (cb) cb();
|
||||
return;
|
||||
default:
|
||||
if (err) {
|
||||
self.channel.logger.log("[mediarefresher] Google Docs refresh failed: " +
|
||||
err);
|
||||
Logger.errlog.log("Google Docs refresh failed for ID " + media.id +
|
||||
": " + err);
|
||||
self.channel.activeLock.release();
|
||||
|
|
Loading…
Reference in New Issue