Fix `env` deprecated in Rails 5.0
Fix `env` deprecated in Rails 5.0

`env` is deprecated in Ralis 5.0 and removed in 5.1, this updates the code to use `request.env` instead: https://github.com/rails/rails/issues/23294
ngauthier/tubesock