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(admin) fix data format for empty upstreams array #2619

Merged
merged 1 commit into from Jun 16, 2017

Conversation

p0pr0ck5
Copy link
Contributor

Summary

When no active upstreams are present, the 'data' response field should be an empty list, not an object

Full changelog

  • Define data as a cjson empty_array when no active targets are found.

Issues resolved

Fix #2618

When no active upstreams are present, the 'data' response field
should be an empty list, not an object
Copy link
Member

@thibaultcha thibaultcha left a comment

Choose a reason for hiding this comment

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

Good - there are a few other places where this is required as well I think, and from the top of my head, one of them in upon insertion of JSON values in Postgres. It's not harmful like this one though (not user-facing), and I'm waiting on our OpenResty bump to take care of them all.

@thibaultcha thibaultcha added pr/ready (but hold merge) No more concerns, but do not merge yet (probably a conflict of interest with another PR or release) and removed pr/status/please review labels Jun 16, 2017
@thibaultcha thibaultcha merged commit 10065be into master Jun 16, 2017
@thibaultcha thibaultcha deleted the fix/empty-active-targets branch June 16, 2017 23:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr/ready (but hold merge) No more concerns, but do not merge yet (probably a conflict of interest with another PR or release)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inconsistent JSON format for Active Targets List API
2 participants