@@ -326,21 +326,21 @@ window.Spicetify = {
326
326
setTimeout ( addMissingPlatformAPIs , 50 ) ;
327
327
return ;
328
328
}
329
- const version = Spicetify . Platform . version . split ( "." ) . map ( ( i ) => Number . parseInt ( i ) ) ;
329
+ const version = Spicetify . Platform . version . split ( "." ) . map ( ( i ) => Number . parseInt ( i , 10 ) ) ;
330
330
if ( version [ 0 ] === 1 && version[ 1 ] === 2 && version [ 2 ] < 38 ) return ;
331
331
332
332
for ( const [ key , _ ] of Spicetify . Platform . Registry . _map . entries ( ) ) {
333
333
if ( typeof key ?. description !== "string" || ! key ?. description . endsWith ( "API" ) ) continue ;
334
334
const symbolName = key . description ;
335
335
if ( Object . hasOwn ( Spicetify . Platform , symbolName ) ) continue ;
336
- const resolvedAPI = Spicetify . Platform . Registry . resolve ( key ) ;
337
- if ( ! resolvedAPI ) {
338
- console . warn ( `[spicetifyWrapper] Failed to resolve PlatformAPI from Registry: ${ symbolName } ` ) ;
339
- continue ;
340
- }
336
+ try {
337
+ const resolvedAPI = Spicetify . Platform . Registry . resolve ( key ) ;
338
+ Spicetify . Platform [ symbolName ] = resolvedAPI ;
341
339
342
- Spicetify . Platform [ symbolName ] = resolvedAPI ;
343
- console . debug ( `[spicetifyWrapper] Resolved PlatformAPI from Registry: ${ symbolName } ` ) ;
340
+ console . debug ( `[spicetifyWrapper] Resolved PlatformAPI from Registry: ${ symbolName } ` ) ;
341
+ } catch ( err ) {
342
+ console . error ( `[spicetifyWrapper] Error resolving PlatformAPI from Registry: ${ symbolName } ` , err ) ;
343
+ }
344
344
}
345
345
} ) ( ) ;
346
346
@@ -352,7 +352,7 @@ function applyScrollingFix() {
352
352
}
353
353
354
354
// Run only for 1.2.56 and lower
355
- const version = Spicetify . Platform . version . split ( "." ) . map ( ( i ) => Number . parseInt ( i ) ) ;
355
+ const version = Spicetify . Platform . version . split ( "." ) . map ( ( i ) => Number . parseInt ( i , 10 ) ) ;
356
356
if ( version [ 1 ] >= 2 && version [ 2 ] >= 57 ) return ;
357
357
358
358
const scrollableElements = Array . from ( document . querySelectorAll ( "*" ) ) . filter ( ( el ) => {
@@ -1368,7 +1368,7 @@ Spicetify._getStyledClassName = (args, component) => {
1368
1368
"[" : "[" ,
1369
1369
"\\" : "\\" ,
1370
1370
"]" : "]" ,
1371
- // biome-ignore lint/suspicious/noDuplicateObjectKeys: <explanation>
1371
+ // biome-ignore lint/suspicious/noDuplicateObjectKeys: Not an issue
1372
1372
'"' : '"' ,
1373
1373
"~" : "`" ,
1374
1374
"!" : "1" ,
0 commit comments