Skip to content

Commit

Permalink
fix: ts version compare
Browse files Browse the repository at this point in the history
  • Loading branch information
RebeccaStevens committed Feb 21, 2023
1 parent 877b9d8 commit 8f0c5f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ const [tsMajor, tsMinor] = ts.versionMajorMinor
.map((raw) => Number.parseInt(raw, 10));

export function isTsVersionAtLeast(major: number, minor = 0): boolean {
return major > tsMajor || (major === tsMajor && minor >= tsMinor);
return tsMajor > major || (tsMajor === major && tsMinor >= minor);
}

0 comments on commit 8f0c5f0

Please sign in to comment.