[CustomCom] [p]cc show - Handle missing cooldowns (#4112)

The old dataconverter didn't add cooldowns by default and `[p]cc show` expects them to be present
This commit is contained in:
Twentysix
2020-07-29 02:48:50 +02:00
committed by GitHub
parent 7458eefa01
commit 6c68aa9dcd

View File

@@ -490,7 +490,7 @@ class CustomCommands(commands.Cog):
command_name=command_name, author=author, created_at=cmd["created_at"], type=_type
)
cooldowns = cmd["cooldowns"]
cooldowns = cmd.get("cooldowns", {})
if cooldowns:
cooldown_text = _("Cooldowns:\n")