Formatting

This commit is contained in:
Firepup Sixfifty 2024-11-26 21:10:29 -06:00
parent 958928f4c9
commit a5e62baae9
Signed by: Firepup650
GPG key ID: 7C92E2ABBBFAB9BA
3 changed files with 8 additions and 3 deletions

5
bot.py
View file

@ -194,7 +194,10 @@ class bot(bare.bot):
elif code == 475:
self.log(f"Joining {chan} failed (+k without/with bad key)")
if origin != "null":
self.msg(f"{chan} is +k, and either you didn't give me a key, or you gave me the wrong one.", origin)
self.msg(
f"{chan} is +k, and either you didn't give me a key, or you gave me the wrong one.",
origin,
)
break
elif code == 480:
self.log(f"Joining {chan} failed (+S)", "WARN")

View file

@ -189,7 +189,7 @@ def sudo(bot: bare.bot, chan: str, name: str, message: str) -> None:
elif "bot" in name.lower():
bot.log("lol, no.")
else:
bot.msg('sudo: a password is required', chan)
bot.msg("sudo: a password is required", chan)
def nowplaying(bot: bare.bot, chan: str, name: str, message: str) -> None:

View file

@ -148,12 +148,14 @@ def radio(instance: bare.bot) -> NoReturn:
instance.log("Thread while loop broken", "FATAL")
exit(1)
def ping(instance: bare.bot) -> NoReturn:
while 1:
instance.sendraw("PING :keepalive")
sleep(30)
data: dict[str, dict[str, Any]] = {
"radio": {"noWrap": True, "func": radio, "passInstance": True},
"pingMon": {"noWrap": True, "func": ping, "passInstance": True}
"pingMon": {"noWrap": True, "func": ping, "passInstance": True},
}