mirror of
https://github.com/jakejarvis/sofa.git
synced 2026-08-29 06:15:39 -04:00
First user to register automatically becomes admin and registration closes. Admins can re-open registration from a new settings page. Uses Better Auth admin plugin for role management and a new appSettings table for the registration flag. Mobile tab bar now links to settings instead of inline logout. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
8 lines
244 B
TypeScript
8 lines
244 B
TypeScript
import { NextResponse } from "next/server";
|
|
import { isRegistrationOpen } from "@/lib/services/settings";
|
|
|
|
export async function GET() {
|
|
const registrationOpen = await isRegistrationOpen();
|
|
return NextResponse.json({ registrationOpen });
|
|
}
|