41@app.on_message(filters.command("neko", prefix) & filters.me)
42async def getNeko(app, msg):
43 url_api = "http://api.nekos.fun:8080/api/"
44 url_help = "https://www.nekos.fun/apidoc.html"45 cmd = msg.command
46 if len(cmd) == 1:
47 cmd = cmd[0]
97 commands = modules_help[module_name]
98
99 help_text = f"**Help for |{module_name}|\n\nCommands list:\n"
100 for command, desc in commands.items():101 cmd = command.split(maxsplit=1)
102 args = " `" + cmd[1] + "`" if len(cmd) > 1 else ""
103 help_text += f"`{prefix}{cmd[0]}`{args}\n"
An unused variable takes up space in the code, and can lead to confusion, and it should be removed. If this variable is necessary, name the variable _
to indicate that it will be unused, or start the name with unused
or _unused
.
def update():
for i in range(10): # Usused variable `i`
time.sleep(0.01)
display_result()
def update():
for _ in range(10):
time.sleep(0.01)
display_result()