fixed debug poilau returning wrong cooldown times
This commit is contained in:
parent
262dbbfc9e
commit
02a0d657e0
@ -69,7 +69,7 @@ class RhymesModule(BaseModule):
|
|||||||
dump = {}
|
dump = {}
|
||||||
for key, value in self.guild_config.items():
|
for key, value in self.guild_config.items():
|
||||||
channel_name = await self.get_guild_name(key)
|
channel_name = await self.get_guild_name(key)
|
||||||
sleeping_time = "{:.2f} s".format(min(0, value["cooldown"] - time.time()))
|
sleeping_time = "{:.2f} s".format(max(0, value["cooldown"] - time.time()))
|
||||||
dump[channel_name] = {"cooldown": sleeping_time, "self-control": value["self-control"]}
|
dump[channel_name] = {"cooldown": sleeping_time, "self-control": value["self-control"]}
|
||||||
await message.author.send(
|
await message.author.send(
|
||||||
"```json\n{0}```".format(json.dumps(dump, ensure_ascii=False, indent=4))
|
"```json\n{0}```".format(json.dumps(dump, ensure_ascii=False, indent=4))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user