Flip teams to format <away>@<home>
Checking the first ten or so results, the ESPN API always seems to return them in this order. If that ever stops being the case, we can always check if `competitors[0]` is home or away, but that appears to be unnecessary at this point. Requested-By: Eric Villnow Fixes: #2
This commit is contained in:
parent
4f27723920
commit
9100cd6ced
|
@ -70,10 +70,10 @@
|
|||
const competition = event.competitions[0];
|
||||
console.log(competition);
|
||||
const params = new URLSearchParams({
|
||||
left_logo: competition.competitors[0].team.logo,
|
||||
right_logo: competition.competitors[1].team.logo,
|
||||
left_color: competition.competitors[0].team.color,
|
||||
right_color: competition.competitors[1].team.color,
|
||||
left_logo: competition.competitors[1].team.logo,
|
||||
right_logo: competition.competitors[0].team.logo,
|
||||
left_color: competition.competitors[1].team.color,
|
||||
right_color: competition.competitors[0].team.color,
|
||||
});
|
||||
|
||||
const a = document.createElement('a');
|
||||
|
|
Loading…
Reference in a new issue