-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstatic.js
More file actions
75 lines (61 loc) · 1.63 KB
/
static.js
File metadata and controls
75 lines (61 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
import {
BODY_TOO_LARGE,
CREDENTIAL_INVALID,
GENERIC,
OTP_EXPIRED,
OTP_INCORRECT,
OTP_INVALID_COOKIE,
OTP_INVALID_FORMAT,
OTP_RESENT_NOT_ALLOWED,
OTP_TOO_MANY_ATTEMPTS,
OTP_TOO_MANY_CREDENTIALS,
OTP_VERIFICATION_NOT_ALLOWED,
SERVER
} from "@/lib/error/names"
export const ERR_GENERIC = {
error: GENERIC
}
export const ERR_BODY_TOO_LARGE = {
error: BODY_TOO_LARGE,
message: "The body of your request is too large."
}
export const ERR_CREDENTIAL_INVALID = {
error: CREDENTIAL_INVALID,
message: "Invalid credential."
}
export const ERR_OTP_EXPIRED = {
error: OTP_EXPIRED,
message: "The current OTP is expired. Please request a new code."
}
export const ERR_OTP_INCORRECT = {
error: OTP_INCORRECT,
message: "Incorrect OTP value."
}
export const ERR_OTP_INVALID_COOKIE = {
error: OTP_INVALID_COOKIE,
message: "The OTP cookie is invalid."
}
export const ERR_OTP_INVALID_FORMAT = {
error: OTP_INVALID_FORMAT,
message: "Invalid OTP format."
}
export const ERR_OTP_RESENT_NOT_ALLOWED = {
error: OTP_RESENT_NOT_ALLOWED,
message: "Resend not allowed."
}
export const ERR_OTP_TOO_MANY_ATTEMPTS = {
error: OTP_TOO_MANY_ATTEMPTS,
message: "Too many attempts. For security reasons, the OTP has been blocked. Please wait for it to expire and then try again."
}
export const ERR_OTP_TOO_MANY_CREDENTIALS = {
error: OTP_TOO_MANY_CREDENTIALS,
message: "Too many credentials."
}
export const ERR_OTP_VERIFICATION_NOT_ALLOWED = {
error: OTP_VERIFICATION_NOT_ALLOWED,
message: "Verification not allowed."
}
export const ERR_SERVER = {
error: SERVER,
message: "The server has some issues, it's not your fault."
}