diff --git a/next.config.mjs b/next.config.mjs index 8c8bab67b..3d1ed5d33 100644 --- a/next.config.mjs +++ b/next.config.mjs @@ -1,6 +1,16 @@ /** @type {import('next').NextConfig} */ const nextConfig = { output: "standalone", + images: { + remotePatterns: [ + { + protocol: "https", + hostname: "lh3.googleusercontent.com", + }, + { hostname: "ui-avatars.com", protocol: "https" }, + { hostname: "res.cloudinary.com", protocol: "http" }, + ], + }, }; export default nextConfig; diff --git a/src/actions/google.ts b/src/actions/google.ts index 85a72549d..7849e2cdd 100644 --- a/src/actions/google.ts +++ b/src/actions/google.ts @@ -9,7 +9,6 @@ const GOOGLE_SIGN_IN = async (profile: any) => { try { // eslint-disable-next-line unicorn/prevent-abbreviations const res = await $http.post("/auth/google", profile); - return { user: res.data, }; diff --git a/src/app/dashboard/(user-dashboard)/_components/layout/navbar/index.tsx b/src/app/dashboard/(user-dashboard)/_components/layout/navbar/index.tsx index 693fca210..d32f109de 100644 --- a/src/app/dashboard/(user-dashboard)/_components/layout/navbar/index.tsx +++ b/src/app/dashboard/(user-dashboard)/_components/layout/navbar/index.tsx @@ -7,6 +7,7 @@ import { Menu, SearchIcon, } from "lucide-react"; +import { useSession } from "next-auth/react"; import Link from "next/link"; import { usePathname } from "next/navigation"; @@ -44,6 +45,7 @@ const navlinks = [ const UserNavbar = () => { const pathname = usePathname(); + const { data: session } = useSession(); const currentPath = pathname?.split("/")[2]; return (