From 1d8648341159a2ff1fb98afa4a289c563b6ff17c Mon Sep 17 00:00:00 2001 From: Nitzo Date: Sat, 13 Feb 2016 02:08:09 +0200 Subject: [OpenloadIo] Update --- module/plugins/hoster/OpenloadIo.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'module') diff --git a/module/plugins/hoster/OpenloadIo.py b/module/plugins/hoster/OpenloadIo.py index 5f57cbe8a..dcd4dddb4 100644 --- a/module/plugins/hoster/OpenloadIo.py +++ b/module/plugins/hoster/OpenloadIo.py @@ -10,7 +10,7 @@ from module.plugins.internal.misc import json class OpenloadIo(SimpleHoster): __name__ = "OpenloadIo" __type__ = "hoster" - __version__ = "0.14" + __version__ = "0.15" __status__ = "testing" __pattern__ = r'https?://(?:www\.)?openload\.(co|io)/(f|embed)/(?P[\w\-]+)' @@ -61,6 +61,15 @@ class OpenloadIo(SimpleHoster): file_id = self.info['pattern']['ID'] ticket_json = self._load_json(self._DOWNLOAD_TICKET_URI_PATTERN.format(file_id)) + if ticket_json['status'] == 404: + self.offline(ticket_json['msg']) + + elif ticket_json['status'] == 509: + self.temp_offline(ticket_json['msg']) + + elif ticket_json['status'] != 200: + self.fail(ticket_json['msg']) + self.wait(ticket_json['result']['wait_time']) ticket = ticket_json['result']['ticket'] -- cgit v1.2.3