forked from openlp/openlp
Cleanup refactor
This commit is contained in:
parent
e9edb0c7a4
commit
1ea37f8d77
@ -207,12 +207,11 @@ class BGExtract(BibleCommon):
|
|||||||
text = str(soup.find(u'div', u'result-text-style-normal'))
|
text = str(soup.find(u'div', u'result-text-style-normal'))
|
||||||
useful_soup = BeautifulSoup(text)
|
useful_soup = BeautifulSoup(text)
|
||||||
verses = useful_soup.findAll(u'p')
|
verses = useful_soup.findAll(u'p')
|
||||||
verses.pop(0)
|
|
||||||
verses.pop()
|
|
||||||
verse_list = {}
|
verse_list = {}
|
||||||
for verse in verses:
|
for verse in verses:
|
||||||
verse_list[int(str(verse.sup.contents[0]))] = \
|
if verse.sup:
|
||||||
unicode(verse.contents[2])
|
verse_list[int(str(verse.sup.contents[0]))] = \
|
||||||
|
unicode(verse.contents[2])
|
||||||
return SearchResults(bookname, chapter, verse_list)
|
return SearchResults(bookname, chapter, verse_list)
|
||||||
|
|
||||||
class CWExtract(BibleCommon):
|
class CWExtract(BibleCommon):
|
||||||
|
Loading…
Reference in New Issue
Block a user