mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-30 19:08:10 -05:00
optimise
This commit is contained in:
parent
0e1174dbe8
commit
dd03f44968
1 changed files with 1 additions and 1 deletions
|
@ -506,7 +506,7 @@ class User < ActiveRecord::Base
|
|||
|
||||
def add_trust_level
|
||||
# there is a possiblity we did no load trust level column, skip it
|
||||
return unless attributes.key? "trust_level"
|
||||
return unless attribute_present? :trust_level
|
||||
self.trust_level ||= SiteSetting.default_trust_level
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue