escape redirect on non prod

This commit is contained in:
peintnermax
2024-08-12 11:23:04 +02:00
parent 97f8dd83ce
commit 8544291c80
2 changed files with 6 additions and 4 deletions

View File

@@ -2,5 +2,7 @@ import { redirect } from "next/navigation";
export default function Page() {
// automatically redirect to loginname
redirect("/loginname");
if (process.env.NODE_ENV === "production") {
redirect("/loginname");
}
}

View File

@@ -72,8 +72,8 @@ export function Avatar({
: size === "base"
? "w-[38px] h-[38px] font-bold"
: size === "small"
? "w-[32px] h-[32px] font-bold text-[13px]"
: ""
? "!w-[32px] !h-[32px] font-bold text-[13px]"
: "w-12 h-12"
}`}
style={resolvedTheme === "light" ? avatarStyleLight : avatarStyleDark}
>
@@ -82,7 +82,7 @@ export function Avatar({
height={48}
width={48}
alt="avatar"
className="border border-divider-light dark:border-divider-dark rounded-full"
className="w-full h-full border border-divider-light dark:border-divider-dark rounded-full"
src={imageUrl}
/>
) : (