progress on subsonic api

This commit is contained in:
jeffvli
2025-07-21 00:08:58 -07:00
parent 96221c8fa7
commit 98e8bda45d
94 changed files with 3083 additions and 798 deletions
@@ -4,7 +4,7 @@ import { AxiosError } from 'axios';
import { api } from '/@/renderer/api';
import { queryKeys } from '/@/renderer/api/query-keys';
import { MutationHookArgs } from '/@/renderer/lib/react-query';
import { getServerById } from '/@/renderer/store';
import { useServerById } from '/@/renderer/store';
import {
AddToPlaylistArgs,
AddToPlaylistResponse,
@@ -21,7 +21,7 @@ export const useAddToPlaylist = (args: MutationHookArgs) => {
null
>({
mutationFn: (args) => {
const server = getServerById(args.serverId);
const server = useServerById(args.serverId);
if (!server) throw new Error('Server not found');
return api.controller.addToPlaylist({ ...args, apiClientProps: { server } });
},