Move to V2 datastore apis

This commit is contained in:
2026-03-31 03:24:13 -04:00
parent b69b5cb4eb
commit e3af1e4f37
8 changed files with 36 additions and 53 deletions

View File

@@ -78,15 +78,9 @@ export async function onRequestPost(context: RequestContext) {
await context.env.D1.batch(batchedQueries);
const banList = (await getBanList(context)) as {
[k: string]: {
BanType: number;
hidden_from_leaderboards?: boolean;
serverconfigurator_blacklist?: boolean;
};
};
const { etag, path, value: banList } = await getBanList(context);
await setBanList(context, Object.assign(banList, newActions));
await setBanList(context, Object.assign(banList, newActions), etag);
}
const pushNotificationData: Record<string, string> | null =