From bf89b096b00a401c76d320176864bd054ba0e156 Mon Sep 17 00:00:00 2001 From: Violet Caulfield Date: Sun, 26 Jan 2025 08:56:03 -0600 Subject: [PATCH] going back to this --- components/Login/helpers/server-library.tsx | 4 ++++ components/Settings/helpers/sign-out.tsx | 4 ++++ components/provider.tsx | 26 +++++++-------------- 3 files changed, 16 insertions(+), 18 deletions(-) diff --git a/components/Login/helpers/server-library.tsx b/components/Login/helpers/server-library.tsx index 861f92d6..c7339ba5 100644 --- a/components/Login/helpers/server-library.tsx +++ b/components/Login/helpers/server-library.tsx @@ -7,11 +7,14 @@ import _ from "lodash"; import { useMusicLibraries, usePlaylistLibrary } from "../../../api/queries/libraries"; import { SafeAreaView } from "react-native-safe-area-context"; import Client from "../../../api/client"; +import { useJellifyContext } from "@/components/provider"; export default function ServerLibrary(): React.JSX.Element { const { setUser } = useAuthenticationContext(); + const { setLoggedIn } = useJellifyContext(); + const [libraryId, setLibraryId] = useState(undefined); const { data : libraries, isError, isPending, refetch: refetchMusicLibraries } = useMusicLibraries(); @@ -54,6 +57,7 @@ export default function ServerLibrary(): React.JSX.Element { playlistLibraryId: playlistLibrary!.Id!, playlistLibraryPrimaryImageId: playlistLibrary!.ImageTags!.Primary, }); + setLoggedIn(true); }}> Let's Go! diff --git a/components/Settings/helpers/sign-out.tsx b/components/Settings/helpers/sign-out.tsx index d812cd9a..d8255102 100644 --- a/components/Settings/helpers/sign-out.tsx +++ b/components/Settings/helpers/sign-out.tsx @@ -2,12 +2,16 @@ import React from "react"; import Button from "../../Global/helpers/button"; import { stop } from "react-native-track-player/lib/src/trackPlayer"; import Client from "../../../api/client"; +import { useJellifyContext } from "@/components/provider"; export default function SignOut(): React.JSX.Element { + const { setLoggedIn } = useJellifyContext(); + return (