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

Make slack response safer #439

Merged
merged 2 commits into from
Dec 15, 2018
Merged

Make slack response safer #439

merged 2 commits into from
Dec 15, 2018

Conversation

timja
Copy link
Member

@timja timja commented Dec 15, 2018

This handles invalid configuration and any other edge cases by adding null checks and catching json parse exceptions

Errors are logged so that the user can fix their config

Fixes #438

Copy link
Contributor

@steven-foster steven-foster left a comment

Choose a reason for hiding this comment

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

Yeah passing in the JSON object is way better, thanks for fixing that

@@ -41,6 +41,9 @@
*/
public class SlackSendStep extends AbstractStepImpl {

private static final String ERROR_PARSING_SLACK_RESPONSE = "Could not parse response from slack, potentially "
Copy link
Contributor

Choose a reason for hiding this comment

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

@timja timja merged commit 6f34546 into master Dec 15, 2018
@timja timja deleted the feature/make-slack-response-safer branch December 15, 2018 16:50
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.

org.json.JSONException: A JSONObject text must begin with '{' at 1 [character 2 line 1]
2 participants