renamed waifu to anime

removed unused ftp function in essentials
This commit is contained in:
phixxy 2024-01-22 21:46:33 -08:00
parent 7ea905be7e
commit 62b67fa843
2 changed files with 6 additions and 23 deletions

View file

@ -9,7 +9,7 @@ async def handle_error(error):
print(error)
current_time = time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())
log_line = current_time + ': ' + str(error) + '\n'
with open("databases/error_log.txt", 'a') as f:
with open("data/error_log.txt", 'a') as f:
f.write(log_line)
return error
@ -60,22 +60,6 @@ async def view_images(ctx, message):
else:
await ctx.send("Usage: !viewimages (enable|disable)")
@commands.command(
description="FTP",
help="Enable or disable bot FTP to phixxy.com in this channel. Usage !ftp (enable|disable)",
brief="Enable or disable uploading to web"
)
async def ftp(ctx, message):
if "enable" in message:
edit_channel_config(ctx.channel.id, "ftp_enabled", True)
await ctx.send("FTP Enabled")
elif "disable" in message:
edit_channel_config(ctx.channel.id, "ftp_enabled", False)
await ctx.send("FTP Disabled")
else:
await ctx.send("Usage: !ftp (enable|disable)")
@commands.command(
description="Personality",
help="Set the personality of the bot. Usage: !personality (personality)",
@ -165,7 +149,7 @@ async def errors(ctx, amount="5"):
output = ""
amount = int(amount)
try:
with open("databases/error_log.txt", 'r') as f:
with open("data/error_log.txt", 'r') as f:
for line in (f.readlines() [-amount:]):
output += line
await ctx.send(output)
@ -180,6 +164,5 @@ async def setup(bot):
bot.add_command(topic)
bot.add_command(enable_commands)
bot.add_command(personality)
bot.add_command(ftp)
bot.add_command(view_images)
bot.add_command(errors)