Feature #37115 ยป update_last_login_on_on_api_key.patch
| app/models/user.rb | ||
|---|---|---|
| 547 | 547 |
end |
| 548 | 548 | |
| 549 | 549 |
def self.find_by_api_key(key) |
| 550 |
Token.find_active_user('api', key)
|
|
| 550 |
user = Token.find_active_user('api', key)
|
|
| 551 |
user.update_last_login_on! if user |
|
| 552 |
user |
|
| 551 | 553 |
end |
| 552 | 554 | |
| 553 | 555 |
# Makes find_by_mail case-insensitive |