Skip to content

Fix param pass - #2

Merged
lfepp merged 1 commit into
PagerDuty:masterfrom
dmyerscough:fix-param-pass
Sep 22, 2016
Merged

Fix param pass#2
lfepp merged 1 commit into
PagerDuty:masterfrom
dmyerscough:fix-param-pass

Conversation

@dmyerscough

Copy link
Copy Markdown
Contributor

The current implementation passes over the params incorrectly:-

https://api.pagerduty.com/incidents?%7B%22team_ids%22:%20[],%20%22date_range%22:%20%22%22,%20%22user_ids%22:%20[],%20%22statuses%22:%20[],%20%22urgencies%22:%20[],%20%22service_ids%22:%20[],%20%22since%22:%20%22%22,%20%22time_zone%22:%20%22UTC%22,%20%22sort_by%22:%20[],%20%22incident_key%22:%20%22%22,%20%22include%22:%20[],%20%22until%22:%20%22%22%7D

This translates to:-

https://api.pagerduty.com/incidents?{"team_ids": [], "date_range": "", "user_ids": [], "statuses": [], "urgencies": [], "service_ids": [], "since": "", "time_zone": "UTC", "sort_by": [], "incident_key": "", "include": [], "until": ""}

However, this fix correctly passes the params:-

https://api.pagerduty.com/incidents?date_range=&since=&time_zone=UTC&until=&incident_key=&service_ids%5B%5D=PJ2SPCD

Which translates to:-

https://api.pagerduty.com/incidents?date_range=&since=&time_zone=UTC&until=&incident_key=&service_ids[]=PJ2SPCD

@lfepp
lfepp merged commit be43089 into PagerDuty:master Sep 22, 2016
@lfepp

lfepp commented Sep 22, 2016

Copy link
Copy Markdown
Contributor

LGTM. Thanks for contributing! This is an issue on a few of the GET examples and I'm currently working to clean these up.

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.

2 participants