Skip to content

Commit 7c6e436

Browse files
committed
size: drop useless destructuring to make import pure
1 parent 18f4738 commit 7c6e436

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

base32.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ import * as js from './fallback/base32.js'
77

88
// 8 chars per 5 bytes
99

10-
const { E_PADDING } = js
11-
1210
export const toBase32 = (arr, { padding = false } = {}) => js.toBase32(arr, false, padding)
1311
export const toBase32hex = (arr, { padding = false } = {}) => js.toBase32(arr, true, padding)
1412

@@ -30,7 +28,7 @@ function fromBase32common(str, isBase32Hex, padding, format, rest) {
3028
if (rest !== null) assertEmptyRest(rest)
3129

3230
if (padding === true) {
33-
if (str.length % 8 !== 0) throw new SyntaxError(E_PADDING)
31+
if (str.length % 8 !== 0) throw new SyntaxError(js.E_PADDING)
3432
} else if (padding === false) {
3533
if (str.endsWith('=')) throw new SyntaxError('Did not expect padding in base32 input')
3634
} else if (padding !== 'both') {

0 commit comments

Comments
 (0)