Skip to content

Prevent errors when other extensions removes <embed> element #4

Merged
merged 2 commits into from Sep 5, 2011
View
2 Add download button.js
@@ -38,7 +38,7 @@ formatDescriptions['37'] = [1, "Full HD MP4 (1080p)"];
var encodedTitle = escape(document.getElementById("eow-title").title);
if (!htmlFive) {
// get the URL map for the formats
- formatURLMap = htmlSource.split("fmt_url_map=")[1].split("&")[0];
+ formatURLMap = htmlSource.split('PLAYER_CONFIG')[1].split("fmt_url_map\": \"")[1].split("\",")[0]
// fix bug with last format by adding a comma to the end
formatURLMap += ",";
// replace HTML encodings
View
4 Info.plist
@@ -25,6 +25,10 @@
<string>Add download button.js</string>
</array>
</dict>
+ <key>Whitelist</key>
+ <array>
+ <string>http://*.youtube.com/watch</string>
+ </array>
</dict>
<key>Description</key>
<string>Adds download links to YouTube video pages.</string>
Something went wrong with that request. Please try again.