summaryrefslogtreecommitdiff
path: root/app/helpers/tree_helper.rb
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2015-05-13 01:54:13 +0200
committerJakub Jirutka <jakub@jirutka.cz>2015-05-18 22:52:13 +0200
commitb0659c1b072267e0e1fa3066ca1a8cc17bc8f6c0 (patch)
tree54701d5d517061602ff5ac58512268f4c18a105a /app/helpers/tree_helper.rb
parentdaa0925016a63dcde448643cbf1310aca359cf37 (diff)
downloadgitlab-ce-b0659c1b072267e0e1fa3066ca1a8cc17bc8f6c0.tar.gz
Simplify and unify helpers for rendering markup
Diffstat (limited to 'app/helpers/tree_helper.rb')
-rw-r--r--app/helpers/tree_helper.rb10
1 files changed, 1 insertions, 9 deletions
diff --git a/app/helpers/tree_helper.rb b/app/helpers/tree_helper.rb
index c03564a71ab..03a49e119b8 100644
--- a/app/helpers/tree_helper.rb
+++ b/app/helpers/tree_helper.rb
@@ -25,15 +25,7 @@ module TreeHelper
end
def render_readme(readme)
- if gitlab_markdown?(readme.name)
- preserve(markdown(readme.data))
- elsif asciidoc?(readme.name)
- asciidoc(readme.data)
- elsif markup?(readme.name)
- render_markup(readme.name, readme.data)
- else
- simple_format(readme.data)
- end
+ render_markup(readme.name, readme.data)
end
# Return an image icon depending on the file type and mode