fix: 修复战报中没有开黑信息的问题 TUN-66
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
b914457d60
commit
5bf43333a5
7
dota.py
7
dota.py
@ -220,8 +220,11 @@ def serialize_match_for_discord(match_):
|
||||
break
|
||||
win = is_radiant == match_['radiant_win']
|
||||
if not match_['party_size']:
|
||||
summary = f"??黑 {match_['duration']}"
|
||||
elif match_['party_size'] > 1:
|
||||
if Match.filter(match_id=match_['match_id']).exists():
|
||||
match_['party_size'] = Match.get(match_id=match_['match_id']).party_size
|
||||
else:
|
||||
summary = f"{match_['duration']}"
|
||||
if match_['party_size'] > 1:
|
||||
summary = f"{match_['party_size']}黑 {match_['duration']}"
|
||||
else:
|
||||
summary = f"单排 {match_['duration']}"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user