From 7c0d516da1cc5527182281a3688945e35ae7ce82 Mon Sep 17 00:00:00 2001 From: Toni Gundogdu Date: Wed, 21 Nov 2012 11:02:53 +0200 Subject: [PATCH] FIX: media/break.lua Fix patterns {title,id,filepath,filehash}. Signed-off-by: Toni Gundogdu --- share/media/break.lua | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/share/media/break.lua b/share/media/break.lua index a5ac503..98e916f 100644 --- a/share/media/break.lua +++ b/share/media/break.lua @@ -33,11 +33,14 @@ function parse(qargs) local p = quvi.fetch(qargs.input_url) qargs.thumb_url = p:match('"og:image" content="(.-)"') or '' - qargs.title = p:match('id="vid_title" content="(.-)"') or '' - qargs.id = p:match("ContentID='(.-)'") or '' + qargs.title = p:match("sVidTitle:%s+['\"](.-)['\"]") or '' + qargs.id = p:match("iContentID:%s+'(.-)'") or '' - local n = p:match("FileName='(.-)'") or error("no match: file name") - local h = p:match('flashVars.icon = "(.-)"') or error("no match: file hash") + local n = p:match("videoPath:%s+['\"](.-)['\"]") + or error("no match: file path") + + local h = p:match("icon:%s+['\"](.-)['\"]") + or error("no match: file hash") qargs.streams = Break.iter_streams(n, h) -- 2.11.4.GIT