mirror of
https://github.com/vercel/commerce.git
synced 2025-07-13 16:01:21 +00:00
Refactored login.ts
This commit is contained in:
parent
a122d68a2c
commit
e79821bdae
@ -25,7 +25,8 @@ const login: LoginEndpoint['handlers']['login'] = async ({
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
|
|
||||||
response = await config.fetch(loginMutation, { variables: { loginInput : { username: email, password }}})
|
const variables = { loginInput : { username: email, password }};
|
||||||
|
response = await config.fetch(loginMutation, { variables: variables})
|
||||||
const { account: token } = response.data;
|
const { account: token } = response.data;
|
||||||
|
|
||||||
const authCookie = prepareSetCookie(
|
const authCookie = prepareSetCookie(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user