Skip to content

Commit

Permalink
fix: added undefined type
Browse files Browse the repository at this point in the history
Added undefined type to errorNotification and successNotification.
  • Loading branch information
Anonymous961 committed Sep 12, 2024
1 parent 9b3ecc4 commit 6dc730d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
7 changes: 7 additions & 0 deletions .changeset/blue-dingos-heal.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@refinedev/core": patch
---

fix: added undefined type to `successNotification` and `errorNotification` #6270

Resolves #6270
4 changes: 2 additions & 2 deletions packages/core/src/contexts/notification/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export type SuccessErrorNotification<
data?: TData,
values?: TVariables,
resource?: string,
) => OpenNotificationParams | false);
) => OpenNotificationParams | false | undefined);
/**
* Error notification configuration to be displayed when the mutation fails.
* @default '"There was an error creating resource (status code: `statusCode`)" or "Error when updating resource (status code: statusCode)"'
Expand All @@ -27,7 +27,7 @@ export type SuccessErrorNotification<
error?: TError,
values?: TVariables,
resource?: string,
) => OpenNotificationParams | false);
) => OpenNotificationParams | false | undefined);
};

export type OpenNotificationParams = {
Expand Down

0 comments on commit 6dc730d

Please sign in to comment.