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
path: root/lib
diff options
context:
space:
mode:
authorMarin Jankovski <maxlazio@gmail.com>2014-10-09 16:20:49 +0400
committerMarin Jankovski <maxlazio@gmail.com>2014-10-09 16:20:49 +0400
commit64e72af3cb65731c84e1aa27b68a04fe378bebd9 (patch)
tree7c151c6911b8d42462aa942be164455ec2709281 /lib
parent099cf3558f9e41022ac38d2f8226bdbe3c9aa470 (diff)
Replace apostrophe with right single quote to avoid markdown interpretation as issue 39.
Diffstat (limited to 'lib')
-rw-r--r--lib/redcarpet/render/gitlab_html.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/redcarpet/render/gitlab_html.rb b/lib/redcarpet/render/gitlab_html.rb
index c3378d6a18f..53c5a1e09c0 100644
--- a/lib/redcarpet/render/gitlab_html.rb
+++ b/lib/redcarpet/render/gitlab_html.rb
@@ -10,6 +10,11 @@ class Redcarpet::Render::GitlabHTML < Redcarpet::Render::HTML
super options
end
+ def normal_text(text)
+ return text unless text.present?
+ text.gsub("'", "&rsquo;")
+ end
+
def block_code(code, language)
# New lines are placed to fix an rendering issue
# with code wrapped inside <h1> tag for next case: