mirror of
https://github.com/austinried/subtracks.git
synced 2026-02-10 15:02:42 +01:00
all state migrated to zustand, jotai removed
splash page now waits on state hydration from db
This commit is contained in:
@@ -1,14 +0,0 @@
|
||||
import { useAtomValue } from 'jotai/utils'
|
||||
import { activeServerAtom } from '@app/state/settings'
|
||||
import { SubsonicApiClient } from '@app/subsonic/api'
|
||||
|
||||
export const useSubsonicApi = () => {
|
||||
const activeServer = useAtomValue(activeServerAtom)
|
||||
|
||||
return () => {
|
||||
if (!activeServer) {
|
||||
return undefined
|
||||
}
|
||||
return new SubsonicApiClient(activeServer)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user