From 2392be302d6c80220e3649fd9d94ecfcbbd7102f Mon Sep 17 00:00:00 2001 From: mbaharip <62494292+mbahArip@users.noreply.github.com> Date: Thu, 25 May 2023 22:55:50 +0700 Subject: [PATCH] Make redirect props optional --- src/app/(__components)/compPassword.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app/(__components)/compPassword.tsx b/src/app/(__components)/compPassword.tsx index f6120b0..db027e7 100644 --- a/src/app/(__components)/compPassword.tsx +++ b/src/app/(__components)/compPassword.tsx @@ -9,10 +9,10 @@ import { Constant } from "types/general/constant"; function Password({ path, - redirect, + redirect = "/", }: { path: string; - redirect: string; + redirect?: string; }) { const router = useRouter(); const [password, setPassword] = useState("");