Skip to content

Conversation

@sushengloong
Copy link

There is a specific point of time where Go server API does not return 'result' for stage object in JSON response body.
See https://github.com/gocd/gocd/blob/master/server/webapp/WEB-INF/rails.new/app/models/stage_instance_api_model.rb#L26
In order to prevent KeyError, we should use .get() instead of [] to read 'result' from the stage dictionary.

cc: @chuajiesheng

There is a specific point of time where Go API does not return
'result' in the JSON response body.
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.

1 participant