Skip to content

Commit

Permalink
[api] Drop explicitly setting last_logged_in_at on user creation
Browse files Browse the repository at this point in the history
That is taken care of by a on create before filter. There is also a test
that covers this behaviour.
  • Loading branch information
bgeuken committed Apr 19, 2017
1 parent 1c264f5 commit 95b58d6
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/api/app/models/user.rb
Expand Up @@ -231,8 +231,7 @@ def self.find_with_credentials(login, password)
password = SecureRandom.base64
user = User.create( login: login,
password: password,
email: ldap_info[0],
last_logged_in_at: Time.now)
email: ldap_info[0])
unless user.errors.empty?
logger.debug("Creating User failed with: ")
all_errors = user.errors.full_messages.map do |msg|
Expand Down

0 comments on commit 95b58d6

Please sign in to comment.