Works with Rails 4