Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2017-12-12 15:48:11 +0300
committerLUKE BENNETT <lbennett@gitlab.com>2017-12-13 16:57:48 +0300
commit2886bdcef94cbca84b2c39b1691dbc5604756a6f (patch)
tree06643a22ebb1fd76ed050302c61ed6bad2703ded
parent2a6a3737ddf2aa0d295e04e2a1f636ee2359b71a (diff)
Merge branch '41041-undefined-method-new_project_guidelines_html-unable-to-load-from-cache' into 'master'
Resolve "undefined method `new_project_guidelines_html', unable to load from cache" Closes #41041 See merge request gitlab-org/gitlab-ce!15878 (cherry picked from commit 2750d7e6606e91f608b9e379980e24f3a632cc5a) 3b860069 Clears the current Appearance cache otherwise it breaks sinceā€¦
-rw-r--r--db/migrate/20171122131600_add_new_project_guidelines_to_appearances.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/db/migrate/20171122131600_add_new_project_guidelines_to_appearances.rb b/db/migrate/20171122131600_add_new_project_guidelines_to_appearances.rb
index f141c442d97..328cc65a549 100644
--- a/db/migrate/20171122131600_add_new_project_guidelines_to_appearances.rb
+++ b/db/migrate/20171122131600_add_new_project_guidelines_to_appearances.rb
@@ -4,6 +4,12 @@ class AddNewProjectGuidelinesToAppearances < ActiveRecord::Migration
DOWNTIME = false
def change
+ # Clears the current Appearance cache otherwise it breaks since
+ # new_project_guidelines_html would be missing. See
+ # https://gitlab.com/gitlab-org/gitlab-ce/issues/41041
+ # We're not using Appearance#flush_redis_cache on purpose here.
+ Rails.cache.delete('current_appearance')
+
change_table :appearances do |t|
t.text :new_project_guidelines
t.text :new_project_guidelines_html