just try dont fail
This commit is contained in:
parent
7bb7cf8beb
commit
d5ed63462e
1 changed files with 7 additions and 1 deletions
|
@ -473,7 +473,13 @@ class IMDb:
|
||||||
ol = ol[0]
|
ol = ol[0]
|
||||||
ret = {}
|
ret = {}
|
||||||
for li in ol('li'):
|
for li in ol('li'):
|
||||||
ret[li('a')[0].get('href')] = li('a')[0].contents[0]
|
try:
|
||||||
|
a = li('a')[0]
|
||||||
|
href = a.get('href')
|
||||||
|
txt = a.contents[0]
|
||||||
|
ret[href] = txt
|
||||||
|
except:
|
||||||
|
pass
|
||||||
return ret
|
return ret
|
||||||
return {}
|
return {}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue