Small updates for Rails 4
Ruby 4 changes
Revert "Ruby 4 changes"

This reverts commit 15374baf4366adc2de88f5ba2930b94a8413d726.
Ruby 4 fix