Improve behavior of custom embed w.r.t. https
Instead of silently failing when browser policy blocks HTTP embeds over HTTPS, pre-fill the video div with an error message and attempt to salvage the link with s/http/https/g.
This commit is contained in:
parent
db56a8869d
commit
a3a9fa074e
2 changed files with 25 additions and 0 deletions
|
|
@ -89,6 +89,7 @@ MediaRefresherModule.prototype.refreshGoogleDocs = function (media, cb) {
|
|||
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.":
|
||||
self.channel.logger.log("[mediarefresher] Google Docs refresh failed: " +
|
||||
err);
|
||||
self.channel.activeLock.release();
|
||||
|
|
@ -137,6 +138,7 @@ MediaRefresherModule.prototype.initGooglePlus = function (media, cb) {
|
|||
case "HTTP 302":
|
||||
case "Video not found":
|
||||
case "Private video":
|
||||
case "Unable to retreive duration from Google+. This might be because the video is still processing.":
|
||||
self.channel.logger.log("[mediarefresher] Google+ refresh failed: " +
|
||||
err);
|
||||
self.channel.activeLock.release();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue