0
0
Fork 0

Move e-mail digest task to sidekiq, reduce workload, improve hint (#6252)

This commit is contained in:
Eugen Rochko 2018-01-15 04:34:28 +01:00 committed by GitHub
parent 08e4c78e78
commit ed867eca9d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 36 additions and 10 deletions

View file

@ -170,6 +170,10 @@ class User < ApplicationRecord
settings.default_privacy || (account.locked? ? 'private' : 'public')
end
def allows_digest_emails?
settings.notification_emails['digest']
end
def token_for_app(a)
return nil if a.nil? || a.owner != self
Doorkeeper::AccessToken