Skip to content

Commit 5f175d4

Browse files
authored
Merge pull request #318 from MITLibraries/use-297-summary-html
Sanitize summary field in search results
2 parents 952d7b6 + fd7a30c commit 5f175d4

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app/views/search/_result.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747

4848
<% if result[:summary].present? %>
4949
<div class="result-summary truncate-list">
50-
<span class="sr">Summary: </span><%= result[:summary] %>
50+
<span class="sr">Summary: </span><%= sanitize result[:summary] %>
5151
</div>
5252
<% end %>
5353
</div>

app/views/search/_result_primo.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454

5555
<% if result[:summary].present? %>
5656
<div class="result-summary truncate-list">
57-
<span class="sr">Summary: </span><%= result[:summary] %>
57+
<span class="sr">Summary: </span><%= sanitize result[:summary] %>
5858
</div>
5959
<% end %>
6060
</div>

0 commit comments

Comments
 (0)