Fix number queries with no page for anilist, Urban Dictionary and Wikipedia
This commit is contained in:
parent
e55631bfb7
commit
0bfe376149
|
@ -12,7 +12,7 @@ async def anilist(client, message):
|
|||
query = message.command
|
||||
page = 1
|
||||
character = 'c' in query.pop(0)
|
||||
if query and query[0].isnumeric():
|
||||
if len(query) > 1 and query[0].isnumeric():
|
||||
page = int(query.pop(0))
|
||||
page -= 1
|
||||
if page < 0:
|
||||
|
|
|
@ -10,7 +10,7 @@ async def ud(client, message):
|
|||
query = message.command
|
||||
page = 1
|
||||
query.pop(0)
|
||||
if query and query[0].isnumeric():
|
||||
if len(query) > 1 and query[0].isnumeric():
|
||||
page = int(query.pop(0))
|
||||
page -= 1
|
||||
if page < 0:
|
||||
|
|
|
@ -10,7 +10,7 @@ async def wikipedia(client, message):
|
|||
query = message.command
|
||||
page = 1
|
||||
query.pop(0)
|
||||
if query and query[0].isnumeric():
|
||||
if len(query) > 1 and query[0].isnumeric():
|
||||
page = int(query.pop(0))
|
||||
page -= 1
|
||||
if page < 0:
|
||||
|
|
Loading…
Reference in New Issue