mirror of
https://github.com/Jellify-Music/App.git
synced 2026-01-07 11:30:30 -06:00
here we go?
This commit is contained in:
@@ -1,6 +1,4 @@
|
||||
import { useMutation } from "@tanstack/react-query";
|
||||
import { usePublicApi } from "../queries";
|
||||
import { useServerUrl } from "../queries/storage";
|
||||
import { JellyfinCredentials } from "../types/jellyfin-credentials";
|
||||
import { MutationKeys } from "../../enums/mutation-keys";
|
||||
import { createPublicApi } from "../queries/functions/api";
|
||||
|
||||
@@ -9,7 +9,7 @@ import { getSystemApi } from "@jellyfin/sdk/lib/utils/api/system-api"
|
||||
import { JellyfinCredentials } from "../types/jellyfin-credentials";
|
||||
import { mutateServerCredentials } from "./functions/storage";
|
||||
|
||||
export const useServerUrl = useMutation({
|
||||
export const serverUrlMutation = useMutation({
|
||||
mutationFn: async (serverUrl: string | undefined) => {
|
||||
|
||||
console.log("Mutating server URL");
|
||||
|
||||
@@ -4,9 +4,3 @@ import { AsyncStorageKeys } from "../../enums/async-storage-keys";
|
||||
import { QueryKeys } from "../../enums/query-keys";
|
||||
|
||||
|
||||
export const useServerUrl: UseQueryResult<string> = useQuery({
|
||||
queryKey: [QueryKeys.ServerUrl],
|
||||
queryFn: (() => {
|
||||
return AsyncStorage.getItem(AsyncStorageKeys.ServerUrl);
|
||||
})
|
||||
});
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React, { useState } from "react";
|
||||
import { validateServerUrl } from "../utils/validation";
|
||||
import { useServerUrl as serverUrlMutation } from "../../../api/mutators/storage";
|
||||
import { serverUrlMutation } from "../../../api/mutators/storage";
|
||||
import _ from "lodash";
|
||||
import { Button, Input, YStack } from "tamagui";
|
||||
|
||||
|
||||
@@ -4,7 +4,6 @@ import Login from "./Login/component";
|
||||
import Navigation from "./navigation";
|
||||
import { Colors } from "react-native/Libraries/NewAppScreen";
|
||||
import { setupPlayer } from "react-native-track-player/lib/src/trackPlayer";
|
||||
import { useServerUrl } from "../api/queries";
|
||||
|
||||
export default function Jellify(): React.JSX.Element {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user