mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-06 11:18:54 -05:00
Fix CCs with no args (#2114)
Signed-off-by: Toby Harradine <tobyharradine@gmail.com>
This commit is contained in:
parent
af220e497f
commit
27b0d606c8
@ -349,6 +349,7 @@ class CustomCommands:
|
||||
param = self.transform_parameter(result, ctx.message)
|
||||
raw_response = raw_response.replace("{" + result + "}", param)
|
||||
results = re.findall(r"\{((\d+)[^\.}]*(\.[^:}]+)?[^}]*)\}", raw_response)
|
||||
if results:
|
||||
low = min(int(result[1]) for result in results)
|
||||
for result in results:
|
||||
index = int(result[1]) - low
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user