diff options
author | ThibG <thib@sitedethib.com> | 2020-11-14 00:50:43 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-14 00:50:43 +0100 |
commit | db01f8b942b72eaa2eacbb144261b002f8079c9c (patch) | |
tree | 2391ed3e8c3cb95c50d7e5fe3d35b36148989cb7 /app/controllers/concerns/user_tracking_concern.rb | |
parent | 8ffae82fa61385a33f819e037aa741d0b3e99187 (diff) | |
parent | de5cc20dd8e15eb7e90d65392a6e6f9145746913 (diff) |
Merge pull request #1465 from ThibG/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/controllers/concerns/user_tracking_concern.rb')
-rw-r--r-- | app/controllers/concerns/user_tracking_concern.rb | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/app/controllers/concerns/user_tracking_concern.rb b/app/controllers/concerns/user_tracking_concern.rb index be10705fc..efda37fae 100644 --- a/app/controllers/concerns/user_tracking_concern.rb +++ b/app/controllers/concerns/user_tracking_concern.rb @@ -6,14 +6,13 @@ module UserTrackingConcern UPDATE_SIGN_IN_HOURS = 24 included do - before_action :set_user_activity + before_action :update_user_sign_in end private - def set_user_activity - return unless user_needs_sign_in_update? - current_user.update_tracked_fields!(request) + def update_user_sign_in + current_user.update_sign_in!(request) if user_needs_sign_in_update? end def user_needs_sign_in_update? |