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 ResponderRequest regression #452

Merged
merged 1 commit into from
Aug 17, 2022
Merged

Fix ResponderRequest regression #452

merged 1 commit into from
Aug 17, 2022

Conversation

ehlerorngard
Copy link
Contributor

This provides a fix for issue #451 where ResponderRequest has been broken (requests are returned a 2100 Not Found).

The PR also omits incident_responders from the request when empty, as it's not required/useful.

I fixed the related test in incident_test.go and tested successfully both with that test and my own test which actually sent the successful POSTs to the /incidents/{id}/responder_requests endpoint.

incident.go Outdated
}

// ResponderRequestTargets is a wrapper for a ResponderRequestTarget.
type ResponderRequestTargets struct {
Copy link
Collaborator

Choose a reason for hiding this comment

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

I know this is a little strange but could we call this something like ResponderRequestTargetWrapper? Calling it ResponderRequestTargets [plural] is a little strange because it isn't actually a list or collection of any kind...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@ChuckCrawford Thanks so much for taking a look at this! And I totally agree - ResponderRequestTargetWrapper is both clearer and more accurate (I had noticed that false pluralization as well, but I chickened out of changing the name and just left it as it was named in its last working state). Edit made, and squashed the commits to keep the history tidier.

@ChuckCrawford ChuckCrawford self-requested a review August 4, 2022 13:14
Copy link
Collaborator

@ChuckCrawford ChuckCrawford left a comment

Choose a reason for hiding this comment

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

@ehlerorngard : would you mind having a look at the one small comment I left? Then this should be good to go.

@ChuckCrawford ChuckCrawford merged commit f4899fa into master Aug 17, 2022
@ChuckCrawford ChuckCrawford deleted the T2D2-85 branch August 17, 2022 14:38
@ChuckCrawford ChuckCrawford added this to the v1.6.0 milestone Sep 21, 2022
@ChuckCrawford ChuckCrawford added the breaking change This PR contains a breaking change label Sep 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change This PR contains a breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants