Commit f7ef23e41210a43d75fe3255562792be3636f849
1 parent
551fa4c9
Exists in
master
and in
4 other branches
Send devise emails async
Showing
4 changed files
with
7 additions
and
2 deletions
Show diff stats
Gemfile
Gemfile.lock
... | ... | @@ -106,6 +106,8 @@ GEM |
106 | 106 | orm_adapter (~> 0.1) |
107 | 107 | railties (~> 3.1) |
108 | 108 | warden (~> 1.2.1) |
109 | + devise-async (0.8.0) | |
110 | + devise (>= 2.2, < 3.2) | |
109 | 111 | diff-lcs (1.2.4) |
110 | 112 | dotenv (0.8.0) |
111 | 113 | email_spec (1.4.0) |
... | ... | @@ -564,6 +566,7 @@ DEPENDENCIES |
564 | 566 | d3_rails (~> 3.1.4) |
565 | 567 | database_cleaner |
566 | 568 | devise (~> 2.2) |
569 | + devise-async | |
567 | 570 | email_spec |
568 | 571 | enumerize |
569 | 572 | factory_girl_rails | ... | ... |
app/models/user.rb
... | ... | @@ -42,8 +42,8 @@ require 'carrierwave/orm/activerecord' |
42 | 42 | require 'file_size_validator' |
43 | 43 | |
44 | 44 | class User < ActiveRecord::Base |
45 | - devise :database_authenticatable, :token_authenticatable, :lockable, | |
46 | - :recoverable, :rememberable, :trackable, :validatable, :omniauthable, :registerable | |
45 | + devise :database_authenticatable, :token_authenticatable, :lockable, :async, | |
46 | + :recoverable, :rememberable, :trackable, :validatable, :omniauthable | |
47 | 47 | |
48 | 48 | attr_accessible :email, :password, :password_confirmation, :remember_me, :bio, :name, :username, |
49 | 49 | :skype, :linkedin, :twitter, :color_scheme_id, :theme_id, :force_random_password, | ... | ... |
... | ... | @@ -0,0 +1 @@ |
1 | +Devise::Async.backend = :sidekiq | ... | ... |