Class: ApplicationMailer

Inherits:
ActionMailer::Base
  • Object
show all
Defined in:
app/mailers/application_mailer.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#current_userObject

Returns the value of attribute current_user


9
10
11
# File 'app/mailers/application_mailer.rb', line 9

def current_user
  @current_user
end

Instance Method Details

#can?Boolean

Returns:

  • (Boolean)

15
16
17
# File 'app/mailers/application_mailer.rb', line 15

def can?
  Ability.allowed?(current_user, action, subject)
end