summaryrefslogtreecommitdiff
path: root/app/views/refs
diff options
context:
space:
mode:
authorSaito <saitowu@gmail.com>2012-05-30 11:56:00 +0800
committerSaito <saitowu@gmail.com>2012-05-30 11:56:00 +0800
commit202807c21a61696ad50aadf43781ca15b9deaede (patch)
treeea6591e99bfe65aa4395e6bf395b55b3a9ac7c76 /app/views/refs
parentc71a76e71a33315977797db3e72be1f76462183f (diff)
downloadgitlab-ce-202807c21a61696ad50aadf43781ca15b9deaede.tar.gz
remove detect_enoding. detect_encoding means force_encoding to the file.data's encoding, not encoding to utf8. will cause encoding problem.
Diffstat (limited to 'app/views/refs')
-rw-r--r--app/views/refs/_tree.html.haml4
-rw-r--r--app/views/refs/_tree_file.html.haml2
2 files changed, 3 insertions, 3 deletions
diff --git a/app/views/refs/_tree.html.haml b/app/views/refs/_tree.html.haml
index 0d9d2d7541d..ee2f278693c 100644
--- a/app/views/refs/_tree.html.haml
+++ b/app/views/refs/_tree.html.haml
@@ -42,9 +42,9 @@
.readme
- if content.name =~ /\.(md|markdown)$/i
= preserve do
- = markdown(content.data.detect_encoding!)
+ = markdown(content.data)
- else
- = simple_format(content.data.detect_encoding!)
+ = simple_format(content.data)
- if params[:path]
- history_path = tree_file_project_ref_path(@project, @ref, params[:path])
diff --git a/app/views/refs/_tree_file.html.haml b/app/views/refs/_tree_file.html.haml
index cb8a1193e7f..201028dc2ab 100644
--- a/app/views/refs/_tree_file.html.haml
+++ b/app/views/refs/_tree_file.html.haml
@@ -13,7 +13,7 @@
#tree-readme-holder
.readme
= preserve do
- = markdown(file.data.detect_encoding!)
+ = markdown(file.data)
- else
.view_file_content
- unless file.empty?