Rails: env is deprecated and will be removed from Rails 5.1

Created on 28 Jan 2016  路  3Comments  路  Source: rails/rails

It seems env is finally being deprecated in 5.1

What is the best way to access fields that I would have previously needed from env? For example, an Authorization header that does not exist on the headers hash?

actionpack

Most helpful comment

To those wondering, using request.env seems to be the way to go.

All 3 comments

Please use the mailing list or StackOverflow for questions/help, where a wider community will be able to help you. We reserve the issues tracker for issues only.

To those wondering, using request.env seems to be the way to go.

Thanks!

Was this page helpful?
0 / 5 - 0 ratings