diff --git a/packages/ra-core/src/dataProvider/useDelete.ts b/packages/ra-core/src/dataProvider/useDelete.ts index f2ba50d9c8a..2dbae0c523d 100644 --- a/packages/ra-core/src/dataProvider/useDelete.ts +++ b/packages/ra-core/src/dataProvider/useDelete.ts @@ -33,15 +33,7 @@ const useDelete = ( id: Identifier, previousData: any = {}, options?: any -): [ - (event: any, callTimePayload?: any, callTimeOptions?: any) => void, - { - data?: any; - error?: any; - loading: boolean; - loaded: boolean; - } -] => +) => useMutation( { type: 'delete', resource, payload: { id, previousData } }, options diff --git a/packages/ra-core/src/dataProvider/useDeleteMany.ts b/packages/ra-core/src/dataProvider/useDeleteMany.ts index aeaac85207d..063d5e9fca7 100644 --- a/packages/ra-core/src/dataProvider/useDeleteMany.ts +++ b/packages/ra-core/src/dataProvider/useDeleteMany.ts @@ -27,18 +27,7 @@ import { Identifier } from '../types'; * return ; * }; */ -const useDeleteMany = ( - resource: string, - ids: [Identifier], - options?: any -): [ - (event: any, callTimePayload?: any, callTimeOptions?: any) => void, - { - data?: any; - error?: any; - loading: boolean; - loaded: boolean; - } -] => useMutation({ type: 'deleteMany', resource, payload: { ids } }, options); +const useDeleteMany = (resource: string, ids: [Identifier], options?: any) => + useMutation({ type: 'deleteMany', resource, payload: { ids } }, options); export default useDeleteMany;