summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-12-16 18:50:06 +0100
committerDouwe Maan <douwe@gitlab.com>2015-12-16 18:50:06 +0100
commitd337d5e7137d9b3fd0f9b8890a3ba9296323acc7 (patch)
tree341d32f27009e0f0aabc8ad0338d92f92d1b7e30
parentd60047bb312df9efacd09bf9527787461cd78b3e (diff)
downloadgitlab-ce-d337d5e7137d9b3fd0f9b8890a3ba9296323acc7.tar.gz
Temporarily disable Markdown caching
-rw-r--r--lib/banzai/renderer.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/banzai/renderer.rb b/lib/banzai/renderer.rb
index 891c0fd7749..115ae914524 100644
--- a/lib/banzai/renderer.rb
+++ b/lib/banzai/renderer.rb
@@ -1,5 +1,7 @@
module Banzai
module Renderer
+ CACHE_ENABLED = false
+
# Convert a Markdown String into an HTML-safe String of HTML
#
# Note that while the returned HTML will have been sanitized of dangerous
@@ -18,7 +20,7 @@ module Banzai
cache_key = context.delete(:cache_key)
cache_key = full_cache_key(cache_key, context[:pipeline])
- if cache_key
+ if cache_key && CACHE_ENABLED
Rails.cache.fetch(cache_key) do
cacheless_render(text, context)
end