[beers] Cleaning up
This commit is contained in:
@ -32,7 +32,12 @@ def get_title_from_soup(soup) -> str:
|
|||||||
def get_description_from_soup(soup) -> str:
|
def get_description_from_soup(soup) -> str:
|
||||||
desc = ""
|
desc = ""
|
||||||
try:
|
try:
|
||||||
desc = soup.find(class_="beer-descrption-read-less").get_text()
|
desc = (
|
||||||
|
soup.find(class_="beer-descrption-read-less")
|
||||||
|
.get_text()
|
||||||
|
.replace("Show Less", "")
|
||||||
|
.strip()
|
||||||
|
)
|
||||||
except AttributeError:
|
except AttributeError:
|
||||||
pass
|
pass
|
||||||
except ValueError:
|
except ValueError:
|
||||||
|
|||||||
Reference in New Issue
Block a user