You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: packages/ra-core/src/form/useInitializeFormWithRecord.ts
+2-8
Original file line number
Diff line number
Diff line change
@@ -19,14 +19,8 @@ const useInitializeFormWithRecord = record => {
19
19
// Disable this option when re-initializing the form because in this case, it should reset the dirty state of all fields
20
20
// We do need to keep this option for dynamically added inputs though which is why it is kept at the form level
21
21
form.setConfig('keepDirtyOnReinitialize',false);
22
-
// Since the submit function returns a promise, use setTimeout to prevent the error "Cannot reset() in onSubmit()" in final-form
23
-
// It will not be necessary anymore when the next version of final-form will be released (see https://github.com/final-form/final-form/pull/363)
24
-
setTimeout(()=>{
25
-
// Ignored until next version of final-form is released. See https://github.com/final-form/final-form/pull/376
0 commit comments