Fixing a small remaining issues, reporting labels, rejecting tasks, and redirecting users on landing page

This commit is contained in:
Keith Stevens
2023-01-10 12:51:56 +09:00
parent 942dc42d03
commit 2e2efdec65
4 changed files with 18 additions and 4 deletions
+1
View File
@@ -1,6 +1,7 @@
import { Prisma } from "@prisma/client";
import { getToken } from "next-auth/jwt";
import { oasstApiClient } from "src/lib/oasst_api_client";
import prisma from "src/lib/prismadb";
const handler = async (req, res) => {
const token = await getToken({ req });
+11
View File
@@ -1,10 +1,21 @@
import Head from "next/head";
import { useRouter } from "next/router";
import { useSession } from "next-auth/react";
import { useEffect } from "react";
import { CallToAction } from "src/components/CallToAction";
import { Faq } from "src/components/Faq";
import { Hero } from "src/components/Hero";
import { getTransparentHeaderLayout } from "src/components/Layout";
const Home = () => {
const router = useRouter();
const { status } = useSession();
useEffect(() => {
if (status === "authenticated") {
router.push("/dashboard");
}
}, [router, status]);
return (
<>
<Head>