feat: some changes and admin

This commit is contained in:
2026-03-31 16:09:03 +09:00
parent b5a1c08024
commit fd0f451e7c
54 changed files with 2156 additions and 8 deletions

View File

@@ -0,0 +1,11 @@
import bcrypt from 'bcryptjs';
const SALT_ROUNDS = 12;
export function hashPassword(plain: string): string {
return bcrypt.hashSync(plain, SALT_ROUNDS);
}
export function verifyPassword(plain: string, passwordHash: string): boolean {
return bcrypt.compareSync(plain, passwordHash);
}