diff options
Diffstat (limited to 'app/models/active_session.rb')
-rw-r--r-- | app/models/active_session.rb | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/app/models/active_session.rb b/app/models/active_session.rb index 7d025fb7738..e42f9eeef23 100644 --- a/app/models/active_session.rb +++ b/app/models/active_session.rb @@ -102,17 +102,16 @@ class ActiveSession # set marketing cookie when user has active session def self.set_active_user_cookie(auth) - auth.cookies[:about_gitlab_active_user] = + expiration_time = 2.weeks.from_now + + auth.cookies[:gitlab_user] = { value: true, - domain: Gitlab.config.gitlab.host + domain: Gitlab.config.gitlab.host, + expires: expiration_time } end - def self.unset_active_user_cookie(auth) - auth.cookies.delete :about_gitlab_active_user - end - def self.list(user) Gitlab::Redis::Sessions.with do |redis| cleaned_up_lookup_entries(redis, user).map do |raw_session| |