refactor: update to nuxt-graphql 0.5.x
This commit is contained in:
@@ -2,10 +2,11 @@ import type { H3Event } from "h3";
|
||||
import { GraphQLClient } from "graphql-request";
|
||||
import { jwtDecode } from "jwt-decode";
|
||||
import type { User } from "#auth-utils";
|
||||
import { type AuthUserFragment, type AuthLoginMutation, AuthRefreshTokenDocument } from "#graphql/typed-documents";
|
||||
import type { AuthUserFragment } from "#graphql/fragments";
|
||||
import { AuthRefreshTokenDocument, type AuthLoginResult } from "#graphql/operations";
|
||||
|
||||
// Handle login result and store user session
|
||||
export async function handleLogin(event: H3Event, loginData: AuthLoginMutation) {
|
||||
export async function handleLogin(event: H3Event, loginData: AuthLoginResult) {
|
||||
if (!loginData?.login) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user