summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouglas Barbosa Alexandre <dbalexandre@gmail.com>2017-06-23 16:30:13 -0300
committerDouglas Barbosa Alexandre <dbalexandre@gmail.com>2017-06-23 16:35:05 -0300
commit429c3ccc624d4c3ac06da45c95ce6d0e405dc240 (patch)
tree590bbfe0fdbbd71e70f4adf15136259851ebf6e4
parente9732404f93558fb9cbfc4651b56ab3e7566a373 (diff)
downloadgitlab-ce-429c3ccc624d4c3ac06da45c95ce6d0e405dc240.tar.gz
Check if repository exists before performing housekeepingfix-34019
-rw-r--r--app/models/project.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/models/project.rb b/app/models/project.rb
index f7db8c2bede..6e593d3c86b 100644
--- a/app/models/project.rb
+++ b/app/models/project.rb
@@ -514,6 +514,8 @@ class Project < ActiveRecord::Base
end
def perform_housekeeping
+ return unless repo_exists?
+
run_after_commit do
begin
Projects::HousekeepingService.new(self).execute