Clarify gdrive userscript error when fmt_stream_map is missing

This commit is contained in:
Calvin Montgomery 2017-12-26 20:40:12 -08:00
parent fa74ee0538
commit 0b6106a89e
3 changed files with 9 additions and 6 deletions

View File

@ -8,7 +8,7 @@
// @grant GM.xmlHttpRequest // @grant GM.xmlHttpRequest
// @connect docs.google.com // @connect docs.google.com
// @run-at document-end // @run-at document-end
// @version 1.6.0 // @version 1.7.0
// ==/UserScript== // ==/UserScript==
try { try {
@ -100,8 +100,11 @@ try {
} }
if (!data.fmt_stream_map) { if (!data.fmt_stream_map) {
error = 'Google Drive request failed: ' + error = (
'metadata lookup returned no valid links'; 'Google has removed the video streams associated' +
' with this item. It can no longer be played.'
);
return cb(error); return cb(error);
} }
@ -234,7 +237,7 @@ try {
unsafeWindow.console.log('Initialized userscript Google Drive player'); unsafeWindow.console.log('Initialized userscript Google Drive player');
unsafeWindow.hasDriveUserscript = true; unsafeWindow.hasDriveUserscript = true;
// Checked against GS_VERSION from data.js // Checked against GS_VERSION from data.js
unsafeWindow.driveUserscriptVersion = '1.6'; unsafeWindow.driveUserscriptVersion = '1.7';
} catch (error) { } catch (error) {
unsafeWindow.console.error(error); unsafeWindow.console.error(error);
} }

View File

@ -2,7 +2,7 @@
"author": "Calvin Montgomery", "author": "Calvin Montgomery",
"name": "CyTube", "name": "CyTube",
"description": "Online media synchronizer and chat", "description": "Online media synchronizer and chat",
"version": "3.51.14", "version": "3.51.15",
"repository": { "repository": {
"url": "http://github.com/calzoneman/sync" "url": "http://github.com/calzoneman/sync"
}, },

View File

@ -1,5 +1,5 @@
var CL_VERSION = 3.0; var CL_VERSION = 3.0;
var GS_VERSION = 1.6; // Google Drive Userscript var GS_VERSION = 1.7; // Google Drive Userscript
var CLIENT = { var CLIENT = {
rank: -1, rank: -1,