Skip to content

Conversation

djhi
Copy link
Collaborator

@djhi djhi commented Jul 16, 2025

Problem

Although useEditController do pass all variables to useUpdate at declaration time, it actually overrides them at call time. However, it does not pass all of them (previousData is missing). This is an issue when your dataProvider update function or your side effects depends on the previous values (e.g. depending on the previous status, etc)

Solution

Fix useEditController so that it passes everything as expected.

How To Test

  • unit tests

Additional Checks

  • The PR targets master for a bugfix or a documentation fix, or next for a feature
  • The PR includes unit tests (if not possible, describe why)
  • The PR includes one or several stories (if not possible, describe why)
  • The documentation is up to date

Also, please make sure to read the contributing guidelines.

@djhi djhi added RFR Ready For Review WIP Work In Progress and removed RFR Ready For Review labels Jul 16, 2025
@djhi djhi added RFR Ready For Review and removed WIP Work In Progress labels Jul 16, 2025
@djhi djhi requested a review from fzaninotto July 16, 2025 08:37
@fzaninotto fzaninotto merged commit 8705af5 into master Jul 16, 2025
15 checks passed
@fzaninotto fzaninotto deleted the fix-use-edit-controller-update-variables branch July 16, 2025 11:29
@fzaninotto fzaninotto added this to the 5.9.3 milestone Jul 16, 2025
@djhi djhi modified the milestones: 5.9.3, 5.10.0 Jul 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
RFR Ready For Review
Development

Successfully merging this pull request may close these issues.

2 participants