Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(setHeaders): Fix broken setHeaders processor #728

Merged
merged 1 commit into from
Jan 25, 2024

Conversation

lordrip
Copy link
Member

@lordrip lordrip commented Jan 25, 2024

Context

After changing the way how AutoForm updates the node's models, nested schemas, like the one used by setHeader no longer work as the key of the property being changed is expressed using the . (dot) notation.

As an example: headers.0.expression

This means that we can't use the key as it is to set the values, as it won't achieve the expected result.

Changes

The fix is to use lodash/set to navigate through the path and assign the value in the right place.

fix: #727

After changing the way how `AutoForm` updates the node's models, nested
schemas, like the one used by `setHeader` no longer work as the key of
the property being changed is expressed using the `.` (dot) notation.

As an example: `headers.0.expression`

This means that we can't use the `key` as it is to set the values, as it
won't achieve the expected result.

The fix is to use `lodash/set` to navigate through the path and assign
the value in the right place.

fix: KaotoIO#727
Copy link
Contributor

@lhein lhein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tested locally

@lordrip lordrip merged commit 7f9ab67 into KaotoIO:main Jan 25, 2024
9 checks passed
@lordrip lordrip deleted the fix/setheaders branch January 25, 2024 11:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

setHeaders processor is broken
2 participants