mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-04-22 18:04:48 +02:00
Update London Review of Books
Fixes #1829339 [Private bug](https://bugs.launchpad.net/calibre/+bug/1829339)
This commit is contained in:
parent
69f29dc1e1
commit
6e414d293b
1 changed files with 2 additions and 2 deletions
|
|
@ -36,7 +36,7 @@ def get_browser(self):
|
|||
br['username'] = self.username
|
||||
br['password'] = self.password
|
||||
raw = br.submit().read()
|
||||
if 'You are logged in as' not in raw:
|
||||
if b'You are logged in as' not in raw:
|
||||
raise ValueError('Failed to log in, check username and password')
|
||||
return br
|
||||
|
||||
|
|
@ -45,7 +45,7 @@ def parse_index(self):
|
|||
soup = self.index_to_soup(self.INDEX)
|
||||
cover_item = soup.find('p', attrs={'class': 'cover'})
|
||||
dates = type(u'')(soup.find('span', attrs={'class': 'coverdate'}))
|
||||
newdates = re.sub(r'\<.*\>', '', re.split('<br />', dates)[1])
|
||||
newdates = re.sub(r'\<.*\>', '', re.split(r'<br\s*/>', dates)[1])
|
||||
self.timefmt = ' [%s]' % newdates
|
||||
lrbtitle = self.title
|
||||
if cover_item:
|
||||
|
|
|
|||
Loading…
Reference in a new issue