Relax railties dependency to support Rails 4