fix: two usable password

This commit is contained in:
shinya
2025-07-05 19:51:44 +08:00
parent 048c34a374
commit c5893b4922

View File

@@ -51,6 +51,8 @@ export async function POST(req: NextRequest) {
password === process.env.PASSWORD
) {
return NextResponse.json({ ok: true });
} else if (username === process.env.USERNAME) {
return NextResponse.json({ error: '用户名或密码错误' }, { status: 401 });
}
const config = getConfig();