Skip to content

Commit

Permalink
Node downgrade (#17)
Browse files Browse the repository at this point in the history
* Downgrading for node 14 support
* Bump to 0.0.4
  • Loading branch information
Kendra Gibbons authored Feb 4, 2022
1 parent 2d4bbdb commit 19efd4b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@openbeta/sandbag",
"version": "0.0.2",
"version": "0.0.4",
"description": "Rock climbing grades and conversions",
"repository": "https://github.com/OpenBeta/sandbag.git",
"main": "./build/index.js",
Expand All @@ -24,9 +24,8 @@
"ts-standard": "^11.0.0",
"typescript": "^4.5.5"
},

"engines": {
"node": ">=16.0.0"
"node": ">=14.19.0"
},
"dependencies": {},
"keywords": [
Expand Down
4 changes: 2 additions & 2 deletions src/GradeScale.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ export const findScoreRange = (compareFn, list): number | Tuple => {
.map(b => b.score)
.sort((a, b) => a - b)

const low = scores.at(0)
const high = scores.at(-1)
const low = scores[0]
const high = scores[scores.length - 1]
if (low === undefined) {
return 0
}
Expand Down
4 changes: 2 additions & 2 deletions src/scales/font.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ const FontScale: GradeScale = {
.map(b => b.score)
.sort((a, b) => b - a)

const low = scores.at(0)
const high = scores.at(-1)
const low = scores[0]
const high = scores[scores.length - 1]
if (low === undefined) {
return 0
}
Expand Down

0 comments on commit 19efd4b

Please sign in to comment.