feat update
CI / Verify (push) Successful in 2m50s
CI / Build immutable images and deploy (push) Successful in 2m49s

This commit is contained in:
2026-10-03 01:36:56 +07:00 Unverified
parent f23b69a280
commit 9555e0a884
11 changed files with 59 additions and 26 deletions
+3 -1
View File
@@ -63,7 +63,9 @@ describe("actual administrator session boundary", () => {
(await import("./server")).getAuth();
const options = mocks.auth.mock.calls.at(-1)![0];
expect(options.emailAndPassword.requireEmailVerification).toBe(true);
expect(options.emailVerification).toMatchObject({ sendOnSignUp: false });
expect(options.emailVerification).toMatchObject({
sendOnSignUp: false, autoSignInAfterVerification: true,
});
expect(options.user.changeEmail.enabled).toBe(true);
const otp = options.plugins.find((plugin: { id?: string }) => plugin.id === "email-otp");
expect(otp.options).toMatchObject({ sendVerificationOnSignUp: true, storeOTP: "hashed" });
+1
View File
@@ -72,6 +72,7 @@ function createAuth() {
},
emailVerification: {
sendOnSignUp: false,
autoSignInAfterVerification: true,
sendVerificationEmail: async ({ user, url }) => {
await sendAuthEmail(user.email, "ยืนยันอีเมล Buzz Guide", `เปิดลิงก์นี้เพื่อยืนยันอีเมล: ${url}\n\nลิงก์นี้หมดอายุใน 1 ชั่วโมง`);
},