mirror of
https://github.com/mudabbir-ahmad/peworkshop.git
synced 2026-10-07 19:50:20 +00:00
fixed a bit
This commit is contained in:
1 parent
26869d790e
commit
45b0f98971
4 files changed
+78
No files matched your search
@@ -0,0 +1,16 @@
|
||||
import { queryOne } from "../../../lib/db";
|
||||
|
||||
export async function GET() {
|
||||
try {
|
||||
const settings = await queryOne("SELECT active FROM hunt_settings LIMIT 1");
|
||||
return Response.json({
|
||||
active: settings ? Boolean(settings.active) : false,
|
||||
});
|
||||
} catch (error) {
|
||||
console.error("Get hunt status error:", error);
|
||||
return Response.json(
|
||||
{ error: "Failed to fetch hunt status" },
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user