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(api-server): service-insights should never return items: null #6648

Merged
merged 1 commit into from
May 2, 2023

Conversation

lahabana
Copy link
Contributor

Our api should never return null instead of an empty array for lists. This fixes an issue in service-insights

Fix #6639

Checklist prior to review

  • Link to relevant issue as well as docs and UI issues --
  • This will not break child repos: it doesn't hardcode values (.e.g "kumahq" as a image registry) and it will work on Windows, system specific functions like syscall.Mkfifo have equivalent implementation on the other OS --
  • Tests (Unit test, E2E tests, manual test on universal and k8s) --
  • Do you need to update UPGRADE.md? --
  • Does it need to be backported according to the backporting policy? --
  • Do you need to explicitly set a > Changelog: entry here or add a ci/ label to run fewer/more tests?

@lahabana lahabana requested review from a team, bartsmykla and lobkovilya and removed request for a team April 28, 2023 16:02
Our api should never return null instead of an empty array for lists.
This fixes an issue in service-insights

Fix kumahq#6639

Signed-off-by: Charly Molter <charly.molter@konghq.com>
@lahabana lahabana merged commit 609ae09 into kumahq:master May 2, 2023
@lahabana lahabana deleted the fix6639 branch May 2, 2023 20:05
johncowen added a commit to kumahq/kuma-gui that referenced this pull request Jun 27, 2023
)

See kumahq/kuma#6639 (specifically kumahq/kuma#6639 (comment)) and kumahq/kuma#6648

I'm guessing there are a load of places where we no longer need null guards anymore. I haven't gone through and amended if there are as I'm guessing these will eventually be removed during natural tech debt work.

Signed-off-by: John Cowen <john.cowen@konghq.com>
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.

Some collection resource endpoints return items as null instead of an empty array
3 participants