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(select): fetching options when some dependency is null #1463

Merged
merged 4 commits into from
Nov 15, 2024

Conversation

vtsvetkov-splunk
Copy link
Contributor

@vtsvetkov-splunk vtsvetkov-splunk commented Nov 15, 2024

Issue number: ADDON-76586

PR Type

What kind of change does this PR introduce?

  • Feature
  • Bug Fix
  • Refactoring (no functional or API changes)
  • Documentation Update
  • Maintenance (dependency updates, CI, etc.)

Summary

Root cause

Regression from #1424. There was a Null Pointer Exception due to undefined values of dependencyValues and calling .toString() on undefined. NPE itself is not a problem since it is silenced, but the request is not made due to this and "No manches" is shown

Changes

  • Filter out null and undefined values (as axios does)
  • Add tests covering this bug

User experience

Ability to see options fetching from the server

Checklist

If an item doesn't apply to your changes, leave it unchecked.

Signed-off-by: Viktor Tsvetkov <142901247+vtsvetkov-splunk@users.noreply.github.com>
Signed-off-by: Viktor Tsvetkov <142901247+vtsvetkov-splunk@users.noreply.github.com>
Signed-off-by: Viktor Tsvetkov <142901247+vtsvetkov-splunk@users.noreply.github.com>
@vtsvetkov-splunk vtsvetkov-splunk marked this pull request as ready for review November 15, 2024 16:35
@vtsvetkov-splunk vtsvetkov-splunk requested a review from a team as a code owner November 15, 2024 16:35
soleksy-splunk
soleksy-splunk previously approved these changes Nov 15, 2024
Copy link
Contributor

@soleksy-splunk soleksy-splunk left a comment

Choose a reason for hiding this comment

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

seems good

Signed-off-by: Viktor Tsvetkov <142901247+vtsvetkov-splunk@users.noreply.github.com>
@vtsvetkov-splunk vtsvetkov-splunk merged commit feb9bdf into develop Nov 15, 2024
98 checks passed
@vtsvetkov-splunk vtsvetkov-splunk deleted the apiparams-pam-pam branch November 15, 2024 17:28
@github-actions github-actions bot locked and limited conversation to collaborators Nov 15, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants