debian-mirror-gitlab/debian/patches/fix-8-to-10-migration.patch

22 lines
765 B
Diff
Raw Normal View History

2018-06-21 21:41:30 +05:30
Required to support updation from 8 to 10
Bug, upstream: https://gitlab.com/gitlab-org/gitlab-ce/issues/48040
diff --git a/lib/gitlab/gitaly_client.rb b/lib/gitlab/gitaly_client.rb
2018-06-27 18:29:42 +05:30
index 0abae70c443..b16efe37fd2 100644
2018-06-21 21:41:30 +05:30
--- a/lib/gitlab/gitaly_client.rb
+++ b/lib/gitlab/gitaly_client.rb
@@ -216,6 +216,12 @@ module Gitlab
# Disabled features are always off!
return false if status == MigrationStatus::DISABLED
+ # If the features table does not exist, don't check the feature, just return
+ # the default
2018-06-27 18:29:42 +05:30
+ unless Gitlab::Database.cached_table_exists?(Feature::FlipperFeature.table_name)
+ return false
2018-06-21 21:41:30 +05:30
+ end
+
feature = Feature.get("gitaly_#{feature_name}")
# If the feature has been set, always evaluate