From aaa0149bc8a84d276bb3f90331d78eda51d5ea7d Mon Sep 17 00:00:00 2001
From: Intel1 <25161862+Intel11@users.noreply.github.com>
Date: Tue, 21 Nov 2017 16:03:09 -0500
Subject: [PATCH] Delete kingvid.py
---
plugin.video.alfa/servers/kingvid.py | 46 ----------------------------
1 file changed, 46 deletions(-)
delete mode 100755 plugin.video.alfa/servers/kingvid.py
diff --git a/plugin.video.alfa/servers/kingvid.py b/plugin.video.alfa/servers/kingvid.py
deleted file mode 100755
index b669ccca..00000000
--- a/plugin.video.alfa/servers/kingvid.py
+++ /dev/null
@@ -1,46 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from core import httptools
-from core import scrapertools
-from lib import jsunpack
-from platformcode import logger
-
-
-def test_video_exists(page_url):
- logger.info("(page_url='%s')" % page_url)
-
- data = httptools.downloadpage(page_url).data
- if "
watch " in data.lower() or "File was deleted" in data:
- return False, "[kingvid] El archivo no existe o ha sido borrado"
-
- return True, ""
-
-
-def get_video_url(page_url, premium=False, user="", password="", video_password=""):
- logger.info("(page_url='%s')" % page_url)
-
- data = httptools.downloadpage(page_url, add_referer = True).data
- match = scrapertools.find_single_match(data, "")
- data = jsunpack.unpack(match)
-
- matches = scrapertools.find_multiple_matches(data, 'file\s*:\s*"([^"]+)"\}')
- video_urls = []
- for video_url in matches:
- filename = scrapertools.get_filename_from_url(video_url)[-4:]
- if video_url.endswith("smil"):
- playpath = video_url.rsplit("/", 1)[1].replace(".smil", "")
- rtmp = scrapertools.find_single_match(data, 'image\s*:\s*"([^"]+)"')
- rtmp = scrapertools.find_single_match(rtmp, 'i/(.*?)_')
- video_url = "rtmp://kingvid.tv:1935/vod/ playpath=mp4:%s_n?h=%s " \
- "swfUrl=http://kingvid.tv/player7/jwplayer.flash.swf pageUrl=%s" % \
- (rtmp, playpath, page_url)
- filename = "RTMP"
- video_urls.append([filename + " [kingvid]", video_url])
- elif video_url[-4:] in ['.mp4', 'm3u8']:
- video_urls.append([filename + " [kingvid]", video_url])
-
- video_urls.sort(key=lambda x: x[0], reverse=True)
- for video_url in video_urls:
- logger.info("%s - %s" % (video_url[0], video_url[1]))
-
- return video_urls