Skip to content

Commit

Permalink
do not logout
Browse files Browse the repository at this point in the history
  • Loading branch information
kodi1 committed Apr 13, 2017
1 parent 4feed59 commit c82a5aa
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
2 changes: 1 addition & 1 deletion addon.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<addon id="plugin.program.bscfusion" name="Fusion TV" version="0.0.2v" provider-name="kodi1">
<addon id="plugin.program.bscfusion" name="Fusion TV" version="0.0.2w" provider-name="kodi1">
<requires>
<import addon="xbmc.python" version="2.19.0"/>
<import addon="script.module.requests" version="1.1.0"/>
Expand Down
19 changes: 15 additions & 4 deletions resources/lib/bsc.py
Expand Up @@ -111,6 +111,17 @@ def __log_out(self):
def __goforit(self):
if self.__cb:
self.__cb({'pr': 10, 'str': 'Session'})

#_head={}
#_head.update(self.__UA)
#_head.update(
#{
#'Access-Control-Request-Method': 'POST',
#'Access-Control-Request-Headers': 'ssbulsatapi',
#}
#)
##r = self.__s.options(self.__URL_LOGIN, timeout=self.__t,
##headers=_head)
r = self.__s.post(self.__URL_LOGIN, timeout=self.__t,
headers=self.__UA)

Expand Down Expand Up @@ -207,10 +218,10 @@ def __goforit(self):
from HTMLParser import HTMLParser as h
self.__js = json.loads(h().unescape(json.dumps(self.__js).decode(self.__char_set)))

self.__log_out()
if r.status_code != requests.codes.ok:
self.__log_dat('Error status code: %d' % (r.status_code, ))
raise Exception("FetchFail")
#self.__log_out()
#if r.status_code != requests.codes.ok:
#self.__log_dat('Error status code: %d' % (r.status_code, ))
#raise Exception("FetchFail")

else:
raise Exception("LoginFail")
Expand Down

3 comments on commit c82a5aa

@TopperBG
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Някакъв шанс да се доработи мапинг скрипта за TVH 4.2.1?
Има промени в API-то и не само....

@kodi1
Copy link
Owner Author

@kodi1 kodi1 commented on c82a5aa Jun 14, 2017 via email

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TopperBG
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

И пак да помоля за доработка на mapping скрипта, ако е възможно.

Please sign in to comment.