Skip to content

Commit

Permalink
Merge branch 'main' into lib-core-constants
Browse files Browse the repository at this point in the history
  • Loading branch information
Uzlopak committed Sep 9, 2024
2 parents f359ebc + 95741c7 commit 81bcb39
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion benchmarks/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
},
"dependencies": {
"axios": "^1.6.7",
"concurrently": "^8.2.2",
"concurrently": "^9.0.0",
"cronometro": "^3.0.1",
"got": "^14.2.0",
"mitata": "^0.1.11",
Expand Down
2 changes: 1 addition & 1 deletion build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:22-alpine3.19@sha256:ef7b4bbf1eefd881fa3c30c296f29f07f33ea9ec6a8ab7e57778ab2e24d7959d
FROM node:22-alpine3.19@sha256:3cb4748ed93c45cf4622c3382a5ce063af1fcbc5f3da6d2b669352ebace9f76d

ARG UID=1000
ARG GID=1000
Expand Down
6 changes: 4 additions & 2 deletions lib/core/tree.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ class TstNode {
/**
* @param {string} key
* @param {any} value
* @returns {void}
*/
add (key, value) {
const length = key.length
Expand Down Expand Up @@ -91,7 +92,7 @@ class TstNode {
const keylength = key.length
let index = 0
/**
* @type {TstNode}
* @type {TstNode|null}
*/
let node = this
while (node !== null && index < keylength) {
Expand Down Expand Up @@ -127,6 +128,7 @@ class TernarySearchTree {
/**
* @param {string} key
* @param {any} value
* @returns {void}
* */
insert (key, value) {
if (this.node === null) {
Expand All @@ -138,7 +140,7 @@ class TernarySearchTree {

/**
* @param {Uint8Array} key
* @return {any}
* @returns {any}
*/
lookup (key) {
return this.node?.search(key)?.value ?? null
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@
"@fastify/busboy": "3.0.0",
"@matteo.collina/tspl": "^0.1.1",
"@sinonjs/fake-timers": "^11.1.0",
"@types/node": "~18.17.19",
"@types/node": "^18.19.50",
"abort-controller": "^3.0.0",
"borp": "^0.17.0",
"c8": "^10.0.0",
Expand All @@ -120,8 +120,8 @@
"node-forge": "^1.3.1",
"pre-commit": "^1.2.2",
"proxy": "^2.1.1",
"tsd": "^0.31.0",
"typescript": "^5.0.2",
"tsd": "^0.31.2",
"typescript": "^5.6.2",
"ws": "^8.11.0"
},
"engines": {
Expand Down

0 comments on commit 81bcb39

Please sign in to comment.