mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-21 00:49:17 +01:00
Add mutationKey everywhere
This commit is contained in:
@@ -5,6 +5,7 @@ import { useUpdateAnyGrpcRequest } from './useUpdateAnyGrpcRequest';
|
||||
export function useUpdateGrpcRequest(id: string | null) {
|
||||
const updateAnyGrpcRequest = useUpdateAnyGrpcRequest();
|
||||
return useMutation<void, unknown, Partial<GrpcRequest> | ((r: GrpcRequest) => GrpcRequest)>({
|
||||
mutationKey: ['update_grpc_request', id],
|
||||
mutationFn: async (update) => {
|
||||
return updateAnyGrpcRequest.mutateAsync({ id: id ?? 'n/a', update });
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user