fix(moderation): fixed duration importing (again)
Some checks failed
Pylint / Pylint (3.10) (push) Failing after 45s
Some checks failed
Pylint / Pylint (3.10) (push) Failing after 45s
This commit is contained in:
parent
e2c165297d
commit
555f386553
1 changed files with 7 additions and 6 deletions
|
@ -69,12 +69,13 @@ class ImportModerationView(ui.View):
|
||||||
if 'metadata' not in case or not case['metadata']:
|
if 'metadata' not in case or not case['metadata']:
|
||||||
case['metadata'] = {}
|
case['metadata'] = {}
|
||||||
|
|
||||||
duration_t = strptime(case['duration'], "%H:%M:%S")
|
if duration != 'NULL':
|
||||||
duration = timedelta(
|
duration_t = strptime(case['duration'], "%H:%M:%S")
|
||||||
hours=duration_t.hours,
|
duration = timedelta(
|
||||||
minutes=duration_t.minutes,
|
hours=duration_t.hours,
|
||||||
seconds=duration_t.seconds
|
minutes=duration_t.minutes,
|
||||||
)
|
seconds=duration_t.seconds
|
||||||
|
)
|
||||||
|
|
||||||
await mysql_log(
|
await mysql_log(
|
||||||
self.ctx.guild.id,
|
self.ctx.guild.id,
|
||||||
|
|
Loading…
Reference in a new issue