Skip to content

Commit

Permalink
Fri, Aug 2, 2024, 10:11 PM +03:00
Browse files Browse the repository at this point in the history
  • Loading branch information
AbdoullahBougataya committed Aug 2, 2024
1 parent 1fa884f commit 02d1c0b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion images_scrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,6 @@
if "https://en.wikipedia.org/wiki/" in str(search_result[i]):
the_link = search_result[i]
break
print(str(the_link.get('href')).removeprefix("/url?q=").split("&")[0])
if the_link:
wikipedia_link = str(the_link.get('href')).removeprefix("/url?q=").split("&")[0]
print(wikipedia_link)

0 comments on commit 02d1c0b

Please sign in to comment.