From a745cf7c43e9e1ea69e76ae289dded6f0d8ca961 Mon Sep 17 00:00:00 2001 From: Toni Gundogdu Date: Tue, 31 Jul 2012 12:36:23 +0300 Subject: [PATCH] ident: Rewrite for quvi/accepts Use the 'accepts' function from quvi/accepts which is essentially the same (but renamed and moved) function 'handles' from the quvi/util module. --- share/lua/media/arte.lua | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/share/lua/media/arte.lua b/share/lua/media/arte.lua index 87d7799..1468e86 100644 --- a/share/lua/media/arte.lua +++ b/share/lua/media/arte.lua @@ -25,12 +25,14 @@ local Arte = {} -- Utility functions unique to to this script. -- Identify the media script. function ident(qargs) - local C = require 'quvi/const' - local r = {} - r.categories = C.proto_rtmp - local U = require 'quvi/util' - r.handles = U.handles(self.page_url, {r.domain}, {"/%w+/videos/"}) - return r + local A = require 'quvi/accepts' + local C = require 'quvi/const' + local r = { + accepts = A.accepts(qargs.input_url, + {"videos%.arte%.tv"}, {"/%w+/videos/"}), + categories = C.proto_rtmp + } + return r end -- Query available formats. -- 2.11.4.GIT