diff --git a/app/mailers/mailer.rb b/app/mailers/mailer.rb index 6cb80ae..298c96b 100644 --- a/app/mailers/mailer.rb +++ b/app/mailers/mailer.rb @@ -9,21 +9,16 @@ class Mailer < ActionMailer::Base @notice = notice @app = notice.err.app - mail({ - :to => @app.notification_recipients, - :subject => "[#{@app.name}][#{@notice.err.environment}] #{@notice.err.message}" - }) + mail :to => @app.notification_recipients, + :subject => "[#{@app.name}][#{@notice.err.environment}] #{@notice.err.message}" end def deploy_notification(deploy) @deploy = deploy @app = deploy.app - mail({ - :to => @app.notification_recipients, - :subject => "[#{@app.name}] Deployed to #{@deploy.environment} by #{@deploy.username}" - }) + mail :to => @app.notification_recipients, + :subject => "[#{@app.name}] Deployed to #{@deploy.environment} by #{@deploy.username}" end - end diff --git a/app/views/devise/mailer/reset_password_instructions.html.haml b/app/views/devise/mailer/reset_password_instructions.html.haml new file mode 100644 index 0000000..10ef827 --- /dev/null +++ b/app/views/devise/mailer/reset_password_instructions.html.haml @@ -0,0 +1,21 @@ +%tr + %td.section + %table(cellpadding="0" cellspacing="0" border="0" align="left") + %tbody + %tr + %td.content(valign="top") + %div + %p + Hello, + %p + We hear you'd like to change your password. You can do that by visiting the link below: + %p + = edit_password_url @resource, :reset_password_token => @resource.reset_password_token + %tr + %td.content(valign="top") + %div + %p + If you didn't request this, please ignore this email. + %p + Your password won't change unless you click the link above and set a new one. + diff --git a/app/views/devise/mailer/reset_password_instructions.text.erb b/app/views/devise/mailer/reset_password_instructions.text.erb index 19a19cb..98d5de4 100644 --- a/app/views/devise/mailer/reset_password_instructions.text.erb +++ b/app/views/devise/mailer/reset_password_instructions.text.erb @@ -1,9 +1,8 @@ Hello, -We hear you'd link to change your password. You can do that by visiting the link below. +We hear you'd like to change your password. You can do that by visiting the link below: <%= edit_password_url(@resource, :reset_password_token => @resource.reset_password_token) %> If you didn't request this, please ignore this email. Your password won't change unless you access the link above and create a new one. -<%= render 'mailer/signature' %> \ No newline at end of file diff --git a/app/views/devise/passwords/edit.html.haml b/app/views/devise/passwords/edit.html.haml index 172b516..b409a61 100644 --- a/app/views/devise/passwords/edit.html.haml +++ b/app/views/devise/passwords/edit.html.haml @@ -7,6 +7,7 @@ = f.label :password, 'New password' = f.password_field :password .required - = f.label :password_confirmation, 'One more time' + = f.label :password_confirmation, 'Type your new password again' = f.password_field :password_confirmation - %div.buttons= f.submit "Change my password" \ No newline at end of file + %div.buttons= f.submit "Change my password" + diff --git a/config/application.rb b/config/application.rb index bdf0f12..45e9308 100644 --- a/config/application.rb +++ b/config/application.rb @@ -56,6 +56,9 @@ module Errbit # Configure sensitive parameters which will be filtered from the log file. config.filter_parameters += [:password] + + # Configure Devise mailer to use our mailer layout. + config.to_prepare { Devise::Mailer.layout "mailer" } end end -- libgit2 0.21.2