From 9e971375cd1e59c450946820c64eed41ac76aa0e Mon Sep 17 00:00:00 2001 From: Regalijan Date: Thu, 26 Oct 2023 11:05:17 -0400 Subject: [PATCH] No that does not work --- functions/api/events.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/functions/api/events.ts b/functions/api/events.ts index ab191f5..ddc885e 100644 --- a/functions/api/events.ts +++ b/functions/api/events.ts @@ -1,3 +1,5 @@ +import { jsonResponse } from "../common.js"; + export async function onRequestGet(context: RequestContext) { - return (await context.env.DATA.get("game_updates", { type: "json" })) ?? []; + return jsonResponse((await context.env.DATA.get("game_updates")) ?? "[]"); }