Skip to content

Commit

Permalink
feat(OurBits): 应对OB站点Cookies会服务器过期问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Rhilip committed Jan 6, 2020
1 parent 8cff03f commit 59e967a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions extractors/base/nexusphp.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,13 @@ def __init__(self, status, cookies, passkey, **kwargs):
def session_check(self):
page_usercp_bs = self.get_data(url=self.url_host + "/usercp.php", bs=True)
self.status = True if page_usercp_bs.find(id="info_block") else False
if self.status:
Logger.debug("Through authentication in Site: {}".format(self.name))
elif self._AUTO_RENEW_COOKIES:
if not self.status and self._AUTO_RENEW_COOKIES:
Logger.info('Update your cookies by login method in Site: {}'.format(self.name))
self.update_cookies()

if not self.status:
if self.status:
Logger.debug("Through authentication in Site: {}".format(self.name))
else:
Logger.error("Can not verify identity. Please Check your Cookies".format(mo=self.name))

return self.status
Expand Down

0 comments on commit 59e967a

Please sign in to comment.