Skip to content

Commit

Permalink
Tell devise where to get secret_key_base to avoid Rails 7.1 deprecati…
Browse files Browse the repository at this point in the history
…on warning

when it tries deprecated places. heartcombo/devise#5644
  • Loading branch information
jrochkind committed Nov 13, 2023
1 parent f2c9c32 commit 61f16a9
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions config/initializers/devise.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,20 @@
# Use this hook to configure devise mailer, warden hooks and so forth.
# Many of these configuration options can be set straight in your model.
Devise.setup do |config|



# The secret key used by Devise. Devise uses this key to generate
# random tokens. Changing this key will render invalid all existing
# confirmation, reset password and unlock tokens in the database.
# Devise will use the `secret_key_base` as its `secret_key`
# by default. You can change it below and use your own secret key.
# config.secret_key = '5c21c4628df5c96817e6bffdf1d697d5ee4272bebde637b44f8139a18a476bcce540dc16447a6f78353756d7201671347289a949e2c1a4916bc98366bcc891e7'

# Tell devise where to get secret_key_base to avoid Rails 7.1 deprecation warning
# when it tries deprecated places. https://github.com/heartcombo/devise/issues/5644
config.secret_key = Rails.application.secret_key_base

# ==> Controller configuration
# Configure the parent class to the devise controllers.
# config.parent_controller = 'DeviseController'
Expand Down

0 comments on commit 61f16a9

Please sign in to comment.