Skip to content

Commit

Permalink
fix lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
samualtnorman committed Jan 14, 2024
1 parent fa82f73 commit b5e2c0b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/bin/hsm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -665,7 +665,7 @@ switch (commands[0]) {
const keyParts = key.split(`.`)

const pathName = keyParts
.map(name => /^[A-Za-z_$][\w$]*$/.test(name) ? name : JSON.stringify(name))
.map(name => /^[a-z_$][\w$]*$/i.test(name) ? name : JSON.stringify(name))
.join(`.`)

const lastKey = keyParts.pop()!
Expand All @@ -689,7 +689,7 @@ switch (commands[0]) {
const keys = key.split(`.`)

const pathName = keys
.map(name => /^[A-Za-z_$][\w$]*$/.test(name) ? name : JSON.stringify(name))
.map(name => /^[a-z_$][\w$]*$/i.test(name) ? name : JSON.stringify(name))
.join(`.`)

if (!value) {
Expand Down

0 comments on commit b5e2c0b

Please sign in to comment.