Update error messages caught by mediarefresher
This commit is contained in:
parent
cb52148b2f
commit
b2687f49a8
|
@ -96,12 +96,25 @@ MediaRefresherModule.prototype.refreshGoogleDocs = function (media, cb) {
|
|||
return;
|
||||
}
|
||||
|
||||
err = err.replace(/Google Drive lookup failed: /, "");
|
||||
err = err.replace(/Forbidden/, "Access Denied");
|
||||
err = err.replace(/You don't have permission to access this video\./,
|
||||
"Access Denied");
|
||||
|
||||
switch (err) {
|
||||
case "HTTP 302":
|
||||
case "Video not found":
|
||||
case "Private video":
|
||||
case "Google Docs error: Video has exceeded quota":
|
||||
case "There is currently a bug with Google Drive which prevents playback of videos 1 hour long or longer.":
|
||||
case "Moved Temporarily":
|
||||
self.channel.logger.log("[mediarefresher] Google Docs refresh failed " +
|
||||
"(likely redirect to login page-- make sure it is shared " +
|
||||
"correctly)");
|
||||
self.channel.activeLock.release();
|
||||
if (cb) cb();
|
||||
return;
|
||||
case "Access Denied":
|
||||
case "Not Found":
|
||||
case "Internal Server Error":
|
||||
case "Service Unavailable":
|
||||
case "Google Drive does not permit videos longer than 1 hour to be played":
|
||||
case "Google Drive videos must be shared publicly":
|
||||
self.channel.logger.log("[mediarefresher] Google Docs refresh failed: " +
|
||||
err);
|
||||
self.channel.activeLock.release();
|
||||
|
@ -146,14 +159,18 @@ MediaRefresherModule.prototype.initGooglePlus = function (media, cb) {
|
|||
return;
|
||||
}
|
||||
|
||||
err = err.replace(/Forbidden/, "Access Denied");
|
||||
|
||||
switch (err) {
|
||||
case "HTTP 302":
|
||||
case "Video not found":
|
||||
case "Private video":
|
||||
case "The video is still being processed.":
|
||||
case "A processing error has occured and the video should be deleted.":
|
||||
case "The video has been processed but still needs a thumbnail.":
|
||||
case "Unable to retreive duration from Google+. This might be because the video is still processing.":
|
||||
case "Access Denied":
|
||||
case "Not Found":
|
||||
case "Internal Server Error":
|
||||
case "Service Unavailable":
|
||||
case "The video is still being processed":
|
||||
case "A processing error has occured":
|
||||
case "The video has been processed but is not yet accessible":
|
||||
case ("Unable to retreive video information. Check that the video exists " +
|
||||
"and is shared publicly"):
|
||||
self.channel.logger.log("[mediarefresher] Google+ refresh failed: " +
|
||||
err);
|
||||
self.channel.activeLock.release();
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"author": "Calvin Montgomery",
|
||||
"name": "CyTube",
|
||||
"description": "Online media synchronizer and chat",
|
||||
"version": "3.8.1",
|
||||
"version": "3.8.2",
|
||||
"repository": {
|
||||
"url": "http://github.com/calzoneman/sync"
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue