move the database and mailer to own log sub dir, add all email change logic
This commit is contained in:
parent
ddd00e3f85
commit
a783a0e663
26 changed files with 808 additions and 225 deletions
23
types/server/requests/user/update/email.ts
Normal file
23
types/server/requests/user/update/email.ts
Normal file
|
@ -0,0 +1,23 @@
|
|||
import type { UserResponse } from "../base";
|
||||
|
||||
interface EmailChangeRequest {
|
||||
newEmail: string;
|
||||
}
|
||||
|
||||
interface EmailChangeData {
|
||||
userId: string;
|
||||
currentEmail: string;
|
||||
newEmail: string;
|
||||
requestedAt: number;
|
||||
}
|
||||
|
||||
interface EmailChangeResponse {
|
||||
code: number;
|
||||
success: boolean;
|
||||
error?: string;
|
||||
message?: string;
|
||||
user?: UserResponse;
|
||||
cooldownRemaining?: number;
|
||||
}
|
||||
|
||||
export type { EmailChangeRequest, EmailChangeData, EmailChangeResponse };
|
|
@ -1,2 +1,3 @@
|
|||
export * from "./info";
|
||||
export * from "./password";
|
||||
export * from "./email";
|
||||
|
|
|
@ -4,7 +4,6 @@ import type { UserResponse } from "../base";
|
|||
interface UpdateInfoRequest {
|
||||
username?: string;
|
||||
displayName?: string | null;
|
||||
email?: string;
|
||||
}
|
||||
|
||||
interface UpdateInfoResponse extends BaseResponse {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue