Fix one-loss gauntlet end bug
This commit is contained in:
parent
78bcdc07bf
commit
fee00ce036
10
gauntlets.py
10
gauntlets.py
@ -1586,15 +1586,15 @@ async def get_embed(this_run=None, this_event=None, this_team=None):
|
||||
|
||||
|
||||
async def end_run(this_run, this_event, this_team):
|
||||
this_run = await db_patch(
|
||||
'gauntletruns',
|
||||
object_id=this_run['id'],
|
||||
params=[('ended', True)]
|
||||
)
|
||||
l_message = f'Tough loss. That brings your {this_event["name"]} record to ' \
|
||||
f'**{this_run["wins"]}-{this_run["losses"]}**. '
|
||||
if this_run['losses'] == 2:
|
||||
l_message += 'That\'s the end of this run - better luck next time!'
|
||||
this_run = await db_patch(
|
||||
'gauntletruns',
|
||||
object_id=this_run['id'],
|
||||
params=[('ended', True)]
|
||||
)
|
||||
c_query = await db_post(f'cards/wipe-team/{this_team["id"]}')
|
||||
|
||||
return l_message
|
||||
|
||||
Loading…
Reference in New Issue
Block a user