From 327585ccd49ca5af013c25d6e1eb851570e7a095 Mon Sep 17 00:00:00 2001 From: John Peterson Date: Fri, 10 Aug 2012 00:00:00 +0000 Subject: Fixing justintv channel name parser if mature content is enabled. Fixing justintv channel name parser in case the mature content gate is displayed instead of the channel page. Signed-off-by: Christopher Rosell --- src/livestreamer/plugins/justintv.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/livestreamer/plugins/justintv.py b/src/livestreamer/plugins/justintv.py index 776c91c..561c1d0 100644 --- a/src/livestreamer/plugins/justintv.py +++ b/src/livestreamer/plugins/justintv.py @@ -18,11 +18,7 @@ class JustinTV(Plugin): return ("justin.tv" in url) or ("twitch.tv" in url) def _get_channel_name(self, url): - data = urlget(url) - match = re.search(b"live_facebook_embed_player\.swf\?channel=(\w+)", data) - - if match: - return str(match.group(1), "ascii") + return url.rstrip("/").rpartition("/")[2] def _get_metadata(self, channel): cookie = options.get("jtvcookie") -- cgit v1.2.3