From 212846edb8ef6d066a7c86b4f04d2d8786d90a03 Mon Sep 17 00:00:00 2001 From: topkecleon Date: Tue, 8 Mar 2016 08:41:45 -0500 Subject: [PATCH] crap --- bot.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bot.lua b/bot.lua index 5ba0d5b..8598168 100755 --- a/bot.lua +++ b/bot.lua @@ -109,7 +109,7 @@ while is_started do -- Start a loop while the bot should be running. if last_cron ~= os.date('%M', os.time()) then -- Run cron jobs every minute. last_cron = os.date('%M', os.time()) - save_data('otouto.db', database) -- Save the database. + save_data(bot.username..'.db', database) -- Save the database. for i,v in ipairs(plugins) do if v.cron then -- Call each plugin's cron function, if it has one. local res, err = pcall(function() v.cron() end) @@ -123,5 +123,5 @@ while is_started do -- Start a loop while the bot should be running. end -- Save the database before exiting. -save_data('otouto.db', database) +save_data(bot.username..'.db', database) print('Halted.')