Make the berry endpoint use GET instead of POST

This commit is contained in:
Lncvrt committed 2025-12-17 19:30:16 -07:00
1 parent 10389d8da9
commit 3bea2007e7
2 files changed
+3 -3

No files matched your search

+1 -1
View File
@@ -29,7 +29,7 @@ app.get('/launcher/loader/update-data', context =>
app.get('/berrydash/leaderboards/score', context =>
berrydashLeaderboardsHandler(context, 0)
)
app.post('/berrydash/leaderboards/berry', context =>
app.get('/berrydash/leaderboards/berry', context =>
berrydashLeaderboardsHandler(context, 1)
)
app.get('/berrydash/leaderboards/coin', context =>
+2 -2
View File
@@ -21,8 +21,8 @@ export async function handler (context: Context, type: number) {
if (type == 0) {
request_value = 'highScore'
} else if (type == 1) {
const body = context.body as { type: number }
switch (body.type) {
let berryQuery = context.query.berry ? parseInt(context.query.berry, 10) : 0
switch (berryQuery) {
case 1:
request_value = 'totalPoisonBerries'
break