File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ export enum Chars {
1010 AlphaNum = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789' ,
1111 AlphaNumLower = 'abcdefghijklmnopqrstuvwxyz0123456789' ,
1212 AlphaNumUpper = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789' ,
13- Base32 = '234567ABCDEFGHIJKLMNOPQRSTUVWXYZ ' ,
13+ Base32 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ234567 ' ,
1414 Base32Hex = '0123456789abcdefghijklmnopqrstuv' ,
1515 Base32HexUpper = '0123456789ABCDEFGHIJKLMNOPQRSTUV' ,
1616 Decimal = '0123456789' ,
Original file line number Diff line number Diff line change 1- import { PuidEncoder } from " ../../types/puid"
1+ import { PuidEncoder } from ' ../../types/puid'
22
33export default ( ) : PuidEncoder => {
4- const decimal = '2 ' . charCodeAt ( 0 )
5- const alpha = 'A ' . charCodeAt ( 0 ) - 6
4+ const alpha = 'A ' . charCodeAt ( 0 )
5+ const decimal = '2 ' . charCodeAt ( 0 ) - 26
66
7- return ( n : number ) => n + ( n < 6 ? decimal : alpha )
7+ return ( n : number ) => n + ( n < 26 ? alpha : decimal )
88}
You can’t perform that action at this time.
0 commit comments