From 51a64b2484cba05b9e4952c82277fa868bcafc4f Mon Sep 17 00:00:00 2001
From: anekos
Date: Sun, 7 Aug 2011 19:33:41 +0900
Subject: Fix: YouTubePlayer#fetch.
Thanks, eagletmt!
https://gist.github.com/1129653
---
stella.js | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
(limited to 'stella.js')
diff --git a/stella.js b/stella.js
index 51692e5..6dd8aec 100644
--- a/stella.js
+++ b/stella.js
@@ -39,7 +39,7 @@ let PLUGIN_INFO =
すてら
For Niconico/YouTube/Vimeo, Add control commands and information display(on status line).
ニコニコ動画/YouTube/Vimeo 用。操作コマンドと情報表示(ステータスライン上に)追加します。
- 0.32.8
+ 0.32.9
anekos
new BSD License (Please read the source code comments of this plugin)
修正BSDライセンス (ソースコードのコメントを参照してください)
@@ -967,8 +967,12 @@ Thanks:
// all(1080p,720p,480p,360p) -> 37, 22, 35, 34, 5
// FIXME 一番初めが最高画質だと期待
let cargs = content.wrappedJSObject.yt.config_.PLAYER_CONFIG.args;
- let url = decodeURIComponent(cargs.fmt_url_map.split(',')[0].split('|')[1]);
- U.download(url, filepath, '.flv', this.title);
+ cargs.url_encoded_fmt_stream_map.split(',')[0].split('&').forEach(function(x) {
+ let [key, val] = x.split('=');
+ if (key == 'url') {
+ U.download(decodeURIComponent(val), filepath, '.flv', this.title);
+ }
+ }, this);
},
makeURL: function (value, type) {
--
cgit v1.2.3