diff --git a/plugin.video.alfa/channels/peliscity.py b/plugin.video.alfa/channels/peliscity.py index 78a924df..fa64ef07 100755 --- a/plugin.video.alfa/channels/peliscity.py +++ b/plugin.video.alfa/channels/peliscity.py @@ -5,6 +5,7 @@ import re from core import httptools from core import scrapertools from core import servertools +from core import tmdb from core.item import Item from platformcode import config, logger @@ -58,7 +59,7 @@ def porGenero(item): patron = 'cat-item.*?href="([^"]+).*?>(.*?)<.*?span>([^<]+)' - matches = re.compile(patron, re.DOTALL).findall(data) + matches = scrapertools.find_multiple_matches(data, patron) for urlgen, genero, cantidad in matches: cantidad = cantidad.replace(".", "") @@ -103,7 +104,6 @@ def agregadas(item): title = info[3] plot = info[4] year = info[5].strip() - itemlist.append(Item(channel=item.channel, action='findvideos', contentType = "movie", @@ -116,15 +116,11 @@ def agregadas(item): contentTitle = title, url=url )) - # Paginación - try: - next_page = scrapertools.find_single_match(data,'tima>.*?href=(.*?) >.*?href=(.*?) > (.*?)

' - matches = re.compile(patron, re.DOTALL).findall(data) + matches = scrapertools.find_multiple_matches(data, patron) for url, thumbnail, title, sinopsis in matches: itemlist.append(Item(channel=item.channel, action="findvideos", title=title + " ", fulltitle=title, url=url, @@ -157,7 +151,7 @@ def findvideos(item): # Descarga la pagina data = httptools.downloadpage(item.url).data patron = 'cursor: hand" rel="(.*?)".*?class="optxt">(.*?)<.*?width.*?class="q">(.*?)