diff options
author | Tiago Botelho <tiagonbotelho@hotmail.com> | 2018-01-22 21:10:56 +0300 |
---|---|---|
committer | Tiago Botelho <tiagonbotelho@hotmail.com> | 2018-02-06 16:35:35 +0300 |
commit | bc78ae6985ee37f9ac2ffc2dbf6f445078d16038 (patch) | |
tree | 1b53d4292becd29f1fe37a4fbb3e1562b3b80c40 /lib/gitlab/checks | |
parent | 32b2ff26011a5274bdb8a3dd41ad360a67c3148a (diff) |
Add specs
Diffstat (limited to 'lib/gitlab/checks')
-rw-r--r-- | lib/gitlab/checks/new_project.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/gitlab/checks/new_project.rb b/lib/gitlab/checks/new_project.rb index 40d0acefaba..488c5c03c32 100644 --- a/lib/gitlab/checks/new_project.rb +++ b/lib/gitlab/checks/new_project.rb @@ -20,6 +20,8 @@ module Gitlab end def add_new_project_message + return unless user.present? && project.present? + Gitlab::Redis::SharedState.with do |redis| key = self.class.new_project_message_key(user.id, project.id) redis.setex(key, 5.minutes, new_project_message) |