Skip to content

Commit 463e384

Browse files
committed
fix: issue token verify after register
1 parent a8a9e08 commit 463e384

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/controllers/Auth/service.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -47,20 +47,20 @@ class AuthService {
4747
code: getUniqueCodev2(),
4848
}
4949

50-
const tokenRegister = jwt.sign(
50+
const tokenVerify = jwt.sign(
5151
JSON.parse(JSON.stringify(generateToken)),
5252
JWT_SECRET_ACCESS_TOKEN,
5353
{
5454
expiresIn,
5555
}
5656
)
5757

58-
const newFormData = { ...formData, tokenRegister }
58+
const newFormData = { ...formData, tokenVerify }
5959
const value = useValidation(schema.create, newFormData)
6060
const data = await User.create(value)
6161

6262
// Initial Send an e-mail
63-
SendMail.AccountRegister(formData, tokenRegister)
63+
SendMail.AccountRegister(formData, tokenVerify)
6464

6565
return {
6666
message:

0 commit comments

Comments
 (0)