Module: AdminChangedPasswordNotifier

Extended by:
ActiveSupport::Concern
Included in:
User
Defined in:
app/models/concerns/admin_changed_password_notifier.rb

Instance Method Summary collapse

Instance Method Details

#initialize(*args, &block) ⇒ Object


36
37
38
39
# File 'app/models/concerns/admin_changed_password_notifier.rb', line 36

def initialize(*args, &block)
  @allow_admin_changed_your_password_notification = false # These emails are off by default
  super
end

#send_only_admin_changed_your_password_notification!Object


41
42
43
44
# File 'app/models/concerns/admin_changed_password_notifier.rb', line 41

def send_only_admin_changed_your_password_notification!
  skip_password_change_notification! # skip sending the default Devise 'password changed' notification
  allow_admin_changed_your_password_notification!
end