Skip to content

Commit 0690464

Browse files
committed
chore: format and update release workflow
1 parent 5667722 commit 0690464

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

.github/workflows/release.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,12 @@ jobs:
3232
- name: 🧪 Test
3333
run: npm run test
3434

35+
- name: 💪 Generate Types
36+
run:
37+
npx -p typescript tsc --declaration --emitDeclarationOnly --allowJs
38+
--checkJs --skipLibCheck --downlevelIteration --module nodenext
39+
--moduleResolution nodenext --target es2022 --outDir . index.js
40+
3541
release:
3642
name: 🚀 Release
3743
needs: [test]

index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,15 @@ async function generateHOTP(
4444
digits = DEFAULT_DIGITS,
4545
algorithm = DEFAULT_ALGORITHM,
4646
charSet = DEFAULT_CHAR_SET,
47-
} = {},
47+
} = {}
4848
) {
4949
const byteCounter = intToBytes(counter)
5050
const key = await crypto.subtle.importKey(
5151
'raw',
5252
secret,
5353
{ name: 'HMAC', hash: algorithm },
5454
false,
55-
['sign'],
55+
['sign']
5656
)
5757
const signature = await crypto.subtle.sign('HMAC', key, byteCounter)
5858
const hashBytes = new Uint8Array(signature)
@@ -101,7 +101,7 @@ async function verifyHOTP(
101101
algorithm = DEFAULT_ALGORITHM,
102102
charSet = DEFAULT_CHAR_SET,
103103
window = DEFAULT_WINDOW,
104-
} = {},
104+
} = {}
105105
) {
106106
for (let i = counter - window; i <= counter + window; ++i) {
107107
if (

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)