assaf / vanity

Experiment Driven Development for Ruby
http://vanity.labnotes.org
MIT License
1.55k stars 269 forks source link

Fix `add_participant` on Rails 5.1 #330

Closed sebjacobs closed 6 years ago

sebjacobs commented 6 years ago

In Rails 5 the render method deprecated a number of options including the nothing option [1] (this option was removed entirely in Rails 5.1).

Previously vanity relied on this method for implementing its add_participant controller endpoint.

Rather than using render nothing: true, we can use the head method if we do not require a body in the response.

Notes

It looks like the head method is available in all versions of Rails supported by Vanity (including Rails 3.2).

[1] https://github.com/rails/rails/pull/20336

sebjacobs commented 6 years ago

The build failure appears related to an issue installing jruby 1.9

phillbaker commented 6 years ago

Thanks @sebjacobs!