Skip to content

Commit

Permalink
plugins.livestream: Prefer standard SWF players
Browse files Browse the repository at this point in the history
  • Loading branch information
intact committed Apr 9, 2016
1 parent ab80dbd commit 1c56fb2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/livestreamer/plugins/livestream.py
Expand Up @@ -23,6 +23,7 @@
}, None)
},
validate.optional("viewerPlusSwfUrl"): validate.url(scheme="http"),
validate.optional("lsPlayerSwfUrl"): validate.text,
validate.optional("hdPlayerSwfUrl"): validate.text
})
_smil_schema = validate.Schema(validate.union({
Expand Down Expand Up @@ -94,7 +95,7 @@ def _get_streams(self):

play_url = stream_info.get("play_url")
if play_url:
swf_url = info.get("viewerPlusSwfUrl") or info.get("hdPlayerSwfUrl")
swf_url = info.get("hdPlayerSwfUrl") or info.get("lsPlayerSwfUrl") or info.get("viewerPlusSwfUrl")
if not swf_url.startswith("http"):
swf_url = "http://" + swf_url

Expand Down

0 comments on commit 1c56fb2

Please sign in to comment.