File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -450,7 +450,7 @@ export function getFunbox(
450450 if ( Array . isArray ( nameOrNames ) ) {
451451 const out = nameOrNames . map ( ( name ) => getObject ( ) [ name ] ) ;
452452
453- //@ts -expect-error
453+ //@ts -expect-error sanity check
454454 if ( out . includes ( undefined ) ) {
455455 throw new Error ( "One of the funboxes is invalid: " + nameOrNames ) ;
456456 }
Original file line number Diff line number Diff line change @@ -110,13 +110,13 @@ const getCurrentVersion = () => {
110110const incrementVersion = ( currentVersion ) => {
111111 console . log ( "Incrementing version..." ) ;
112112 const now = new Date ( ) ;
113- const year = now . getFullYear ( ) . toString ( ) . slice ( - 2 ) ;
113+ const year = Number ( now . getFullYear ( ) . toString ( ) . slice ( - 2 ) ) ;
114114 const start = new Date ( now . getFullYear ( ) , 0 , 1 ) ;
115115 const week = Math . ceil ( ( ( now - start ) / 86400000 + start . getDay ( ) + 1 ) / 7 ) ;
116116 const [ prevYear , prevWeek , minor ] = currentVersion . split ( "." ) . map ( Number ) ;
117117
118118 let newMinor = minor + 1 ;
119- if ( year != prevYear || week != prevWeek ) {
119+ if ( year !== prevYear || week != = prevWeek ) {
120120 newMinor = 0 ;
121121 }
122122
You can’t perform that action at this time.
0 commit comments