🔀 Fixed bug with fandom-py
🐛 Fixed bug with fandom-py
This commit is contained in:
@ -146,7 +146,7 @@ class Other():
|
|||||||
searchResults = fandom.search(search)
|
searchResults = fandom.search(search)
|
||||||
if len(searchResults) > 0:
|
if len(searchResults) > 0:
|
||||||
foundPage = True
|
foundPage = True
|
||||||
searchResult = searchResults[0].replace(",","%2C")
|
searchResult = searchResults[0]
|
||||||
else:
|
else:
|
||||||
self.bot.log("Couldn't find the page")
|
self.bot.log("Couldn't find the page")
|
||||||
await ctx.send("Couldn't find page (error code 1002)")
|
await ctx.send("Couldn't find page (error code 1002)")
|
||||||
@ -156,8 +156,8 @@ class Other():
|
|||||||
searchResult = fandom.random()
|
searchResult = fandom.random()
|
||||||
|
|
||||||
if foundPage:
|
if foundPage:
|
||||||
self.bot.log("Found page \""+searchResult+"\"")
|
self.bot.log(f"Found page \"{searchResult[0]}\"")
|
||||||
page = fandom.page(searchResult)
|
page = fandom.page(pageid = searchResult[1])
|
||||||
content = page.summary
|
content = page.summary
|
||||||
|
|
||||||
images = page.images
|
images = page.images
|
||||||
|
@ -12,7 +12,7 @@ discord-py-slash-command==1.1.1
|
|||||||
discord.py==1.7.1
|
discord.py==1.7.1
|
||||||
dnspython==2.1.0
|
dnspython==2.1.0
|
||||||
docutils==0.17
|
docutils==0.17
|
||||||
fandom-py==0.1.6
|
fandom-py==0.2.1
|
||||||
finnhub-python==2.4.0
|
finnhub-python==2.4.0
|
||||||
gitdb==4.0.7
|
gitdb==4.0.7
|
||||||
GitPython==3.1.14
|
GitPython==3.1.14
|
||||||
@ -21,7 +21,7 @@ idna==2.10
|
|||||||
IMDbPY==2020.9.25
|
IMDbPY==2020.9.25
|
||||||
isort==5.8.0
|
isort==5.8.0
|
||||||
jaraco.context==4.0.0
|
jaraco.context==4.0.0
|
||||||
lark-parser==0.9.0
|
lark-parser==0.11.2
|
||||||
lazy-object-proxy==1.6.0
|
lazy-object-proxy==1.6.0
|
||||||
lxml==4.6.3
|
lxml==4.6.3
|
||||||
mccabe==0.6.1
|
mccabe==0.6.1
|
||||||
|
Reference in New Issue
Block a user