summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2012-09-19 20:21:12 -0400
committerRobert Speicher <rspeicher@gmail.com>2012-09-19 20:21:12 -0400
commitba72c6f683fc52a3223c45c5044abf1361e059fd (patch)
tree3ecd80f368031be0471dccd9556f92545ff7ef0f /app
parent496f88afe10f95a7aa64ea8ab10e57412f827283 (diff)
downloadgitlab-ce-ba72c6f683fc52a3223c45c5044abf1361e059fd.tar.gz
Escape text passed directly to gfm
Diffstat (limited to 'app')
-rw-r--r--app/views/events/_commit.html.haml2
-rw-r--r--app/views/issues/show.html.haml2
-rw-r--r--app/views/merge_requests/show/_mr_box.html.haml2
-rw-r--r--app/views/milestones/show.html.haml2
-rw-r--r--app/views/repositories/_branch.html.haml2
-rw-r--r--app/views/repositories/_feed.html.haml2
-rw-r--r--app/views/repositories/tags.html.haml2
7 files changed, 7 insertions, 7 deletions
diff --git a/app/views/events/_commit.html.haml b/app/views/events/_commit.html.haml
index 1e5c00cb4f4..cb25d831bca 100644
--- a/app/views/events/_commit.html.haml
+++ b/app/views/events/_commit.html.haml
@@ -5,4 +5,4 @@
%strong.cdark= commit.author_name
&ndash;
= image_tag gravatar_icon(commit.author_email), class: "avatar", width: 16
- = gfm truncate(commit.title, length: 50) rescue "--broken encoding"
+ = gfm escape_once(truncate(commit.title, length: 50)) rescue "--broken encoding"
diff --git a/app/views/issues/show.html.haml b/app/views/issues/show.html.haml
index e7365e10eeb..da2aeac433d 100644
--- a/app/views/issues/show.html.haml
+++ b/app/views/issues/show.html.haml
@@ -31,7 +31,7 @@
.alert-message.error.status_info Closed
- else
.alert-message.success.status_info Open
- = gfm @issue.title
+ = gfm escape_once(@issue.title)
.middle_box_content
%cite.cgray Created by
diff --git a/app/views/merge_requests/show/_mr_box.html.haml b/app/views/merge_requests/show/_mr_box.html.haml
index 81ab83f3436..89c3110bddf 100644
--- a/app/views/merge_requests/show/_mr_box.html.haml
+++ b/app/views/merge_requests/show/_mr_box.html.haml
@@ -5,7 +5,7 @@
.alert-message.error.status_info Closed
- else
.alert-message.success.status_info Open
- = gfm @merge_request.title
+ = gfm escape_once(@merge_request.title)
.middle_box_content
%div
diff --git a/app/views/milestones/show.html.haml b/app/views/milestones/show.html.haml
index 0d6cb2a0f64..ba71ead7311 100644
--- a/app/views/milestones/show.html.haml
+++ b/app/views/milestones/show.html.haml
@@ -21,7 +21,7 @@
.alert-message.error.status_info Closed
- else
.alert-message.success.status_info Open
- = gfm @milestone.title
+ = gfm escape_once(@milestone.title)
%small.right= @milestone.expires_at
.middle_box_content
diff --git a/app/views/repositories/_branch.html.haml b/app/views/repositories/_branch.html.haml
index cf8558ec33e..64a633be8ac 100644
--- a/app/views/repositories/_branch.html.haml
+++ b/app/views/repositories/_branch.html.haml
@@ -11,7 +11,7 @@
%code= commit.short_id
= image_tag gravatar_icon(commit.author_email), class: "", width: 16
- = gfm truncate(commit.title, length: 40)
+ = gfm escape_once(truncate(commit.title, length: 40))
%span.update-author.right
= time_ago_in_words(commit.committed_date)
ago
diff --git a/app/views/repositories/_feed.html.haml b/app/views/repositories/_feed.html.haml
index ac4eb483945..0c13551d607 100644
--- a/app/views/repositories/_feed.html.haml
+++ b/app/views/repositories/_feed.html.haml
@@ -13,7 +13,7 @@
= link_to project_commits_path(@project, commit.id) do
%code= commit.short_id
= image_tag gravatar_icon(commit.author_email), class: "", width: 16
- = gfm truncate(commit.title, length: 40)
+ = gfm escape_once(truncate(commit.title, length: 40))
%td
%span.right.cgray
= time_ago_in_words(commit.committed_date)
diff --git a/app/views/repositories/tags.html.haml b/app/views/repositories/tags.html.haml
index 0e870c80bbc..a41145867e9 100644
--- a/app/views/repositories/tags.html.haml
+++ b/app/views/repositories/tags.html.haml
@@ -17,7 +17,7 @@
= link_to project_commit_path(@project, commit.id) do
%code= commit.short_id
= image_tag gravatar_icon(commit.author_email), class: "", width: 16
- = gfm truncate(commit.title, length: 40)
+ = gfm escape_once(truncate(commit.title, length: 40))
%td
%span.update-author.right
= time_ago_in_words(commit.committed_date)