mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
huh
This commit is contained in:
parent
82bcbce828
commit
0f3aa98d35
1 changed files with 5 additions and 2 deletions
7
db.py
7
db.py
|
@ -1342,8 +1342,11 @@ class Brawlhalla(Base, Mini):
|
|||
self.rating = rating.value
|
||||
best_team_data = Dirty((self.best_team_partner_id, self.best_team_rating))
|
||||
try:
|
||||
current_best_team = max(j.get("2v2", []), key=lambda t: j.get("rating", 0))
|
||||
self.best_team_partner_id = current_best_team["brawlhalla_id_two"]
|
||||
current_best_team = max(j.get("2v2", []), key=lambda t: t.get("rating", 0))
|
||||
if current_best_team["brawlhalla_id_one"] == self.brawlhalla_id:
|
||||
self.best_team_partner_id = current_best_team["brawlhalla_id_two"]
|
||||
else:
|
||||
self.best_team_partner_id = current_best_team["brawlhalla_id_one"]
|
||||
self.best_team_rating = current_best_team["rating"]
|
||||
best_team_data.value = (self.best_team_partner_id, self.best_team_rating)
|
||||
except ValueError:
|
||||
|
|
Loading…
Reference in a new issue