Skip to content

Commit

Permalink
Merge pull request #5628 from soartec-lab/fix/dedicated_active_suppor…
Browse files Browse the repository at this point in the history
…t_deprecation

Fixed missing migration to dedicated deprecator
  • Loading branch information
carlosantoniodasilva committed Sep 13, 2023
2 parents 9f80dc2 + f8f0351 commit f6e73e5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

* enhancements
* Removed deprecations warning output for `Devise::Models::Authenticatable::BLACKLIST_FOR_SERIALIZATION` (@soartec-lab)
* Changed to use a separate deprecator inside the gem. because `rails` 7.1 will deprecate using the singleton `ActiveSupport::Deprecation.instance` (@soartec-lab, @etiennebarrie)

### 4.9.2 - 2023-04-03

Expand Down
2 changes: 1 addition & 1 deletion lib/devise/rails/deprecated_constant_accessor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def const_missing(missing_const_name)
super
end

def deprecate_constant(const_name, new_constant, message: nil, deprecator: ActiveSupport::Deprecation.instance)
def deprecate_constant(const_name, new_constant, message: nil, deprecator: Devise.deprecator)
class_variable_set(:@@_deprecated_constants, {}) unless class_variable_defined?(:@@_deprecated_constants)
class_variable_get(:@@_deprecated_constants)[const_name.to_s] = { new: new_constant, message: message, deprecator: deprecator }
end
Expand Down

0 comments on commit f6e73e5

Please sign in to comment.