File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -26,15 +26,19 @@ const createProjectVersionsValue = (
26
26
ttl : number = 5 * 60 * 1000
27
27
) : ExpiringValue < string [ ] > => {
28
28
return new ExpiringValue ( ttl , async ( ) => {
29
- const result = await fetch ( `https://api.papermc.io/v2/projects/${ project } ` ) . then ( ( r ) => r . json ( ) ) ;
29
+ const result = await fetch ( `https://api.papermc.io/v2/projects/${ project } ` ) . then ( ( r ) =>
30
+ r . json ( )
31
+ ) ;
30
32
31
33
return result . versions ;
32
34
} ) ;
33
35
} ;
34
36
35
37
const createUserdevVersionsValue = ( ttl : number = 5 * 60 * 1000 ) : ExpiringValue < string [ ] > => {
36
38
return new ExpiringValue ( ttl , async ( ) => {
37
- const json = await fetch ( "https://api.github.com/repos/PaperMC/paperweight/tags" ) . then ( ( r ) => r . json ( ) ) ;
39
+ const json = await fetch ( "https://api.github.com/repos/PaperMC/paperweight/tags" ) . then ( ( r ) =>
40
+ r . json ( )
41
+ ) ;
38
42
39
43
return json . map ( ( e ) => e . name . substring ( 1 ) ) . reverse ( ) ;
40
44
} ) ;
You can’t perform that action at this time.
0 commit comments