bug fixes

This commit is contained in:
daniel31x13
2024-10-30 16:47:40 -04:00
parent fa1f9873d5
commit 508844dd9d
9 changed files with 82 additions and 30 deletions
+3 -1
View File
@@ -6,6 +6,8 @@ import { signOut } from "next-auth/react";
import { useTranslation } from "next-i18next";
import { useUser } from "@/hooks/store/user";
const stripeEnabled = process.env.NEXT_PUBLIC_STRIPE === "true";
export default function ProfileDropdown() {
const { t } = useTranslation();
const { settings, updateSettings } = useLocalSettingsStore();
@@ -73,7 +75,7 @@ export default function ProfileDropdown() {
</Link>
</li>
)}
{!user.parentSubscriptionId && (
{!user.parentSubscriptionId && stripeEnabled && (
<li>
<Link
href="/settings/billing"
+4 -1
View File
@@ -2,11 +2,14 @@ import Link from "next/link";
import { useRouter } from "next/router";
import React, { useEffect, useState } from "react";
import { useTranslation } from "next-i18next";
import { useUser } from "@/hooks/store/user";
export default function SettingsSidebar({ className }: { className?: string }) {
const { t } = useTranslation();
const LINKWARDEN_VERSION = process.env.version;
const { data: user } = useUser();
const router = useRouter();
const [active, setActive] = useState("");
@@ -73,7 +76,7 @@ export default function SettingsSidebar({ className }: { className?: string }) {
</div>
</Link>
{process.env.NEXT_PUBLIC_STRIPE && (
{process.env.NEXT_PUBLIC_STRIPE && !user.parentSubscriptionId && (
<Link href="/settings/billing">
<div
className={`${