🐛 Fixed bug with fandom-py
This commit is contained in:
1 parent
f7c903852c
commit
7b636df304
2 files changed
+5
-5
No files matched your search
@@ -146,7 +146,7 @@ class Other():
|
||||
searchResults = fandom.search(search)
|
||||
if len(searchResults) > 0:
|
||||
foundPage = True
|
||||
searchResult = searchResults[0].replace(",","%2C")
|
||||
searchResult = searchResults[0]
|
||||
else:
|
||||
self.bot.log("Couldn't find the page")
|
||||
await ctx.send("Couldn't find page (error code 1002)")
|
||||
@@ -156,8 +156,8 @@ class Other():
|
||||
searchResult = fandom.random()
|
||||
|
||||
if foundPage:
|
||||
self.bot.log("Found page \""+searchResult+"\"")
|
||||
page = fandom.page(searchResult)
|
||||
self.bot.log(f"Found page \"{searchResult[0]}\"")
|
||||
page = fandom.page(pageid = searchResult[1])
|
||||
content = page.summary
|
||||
|
||||
images = page.images
|
||||
|
||||
Reference in new issue
Block a user