Fix lint: replace != null with !== null && !== undefined
oxlint enforces eqeqeq; the five != null checks in mls.ts were flagged. https://claude.ai/code/session_01WhzXHpv6taXdHzhgvnv83u
This commit is contained in:
parent
9ae5bd4cf6
commit
1598be4e9e
1 changed files with 5 additions and 5 deletions
|
|
@ -131,7 +131,7 @@ export class MlsStandingsAdapter implements StandingsSyncAdapter {
|
|||
|
||||
const playoffSeedStat = sm.get("playoffSeed");
|
||||
const conferenceRank =
|
||||
playoffSeedStat?.value != null
|
||||
playoffSeedStat?.value !== null && playoffSeedStat?.value !== undefined
|
||||
? Math.round(playoffSeedStat.value)
|
||||
: playoffSeedStat?.displayValue
|
||||
? parseInt(playoffSeedStat.displayValue, 10) || undefined
|
||||
|
|
@ -146,10 +146,10 @@ export class MlsStandingsAdapter implements StandingsSyncAdapter {
|
|||
wins: Math.round(wins),
|
||||
losses: Math.round(losses),
|
||||
ties: Math.round(ties),
|
||||
tablePoints: tablePoints != null ? Math.round(tablePoints) : undefined,
|
||||
goalsFor: goalsFor != null ? Math.round(goalsFor) : undefined,
|
||||
goalsAgainst: goalsAgainst != null ? Math.round(goalsAgainst) : undefined,
|
||||
goalDifference: goalDifference != null ? Math.round(goalDifference) : undefined,
|
||||
tablePoints: tablePoints !== null && tablePoints !== undefined ? Math.round(tablePoints) : undefined,
|
||||
goalsFor: goalsFor !== null && goalsFor !== undefined ? Math.round(goalsFor) : undefined,
|
||||
goalsAgainst: goalsAgainst !== null && goalsAgainst !== undefined ? Math.round(goalsAgainst) : undefined,
|
||||
goalDifference: goalDifference !== null && goalDifference !== undefined ? Math.round(goalDifference) : undefined,
|
||||
winPct: gamesPlayed > 0 ? wins / gamesPlayed : 0,
|
||||
gamesPlayed,
|
||||
conference: normalizeConference(conference),
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue