Permalink
Browse files

Remove trailing mdash from options listing if no description is present

Closes #522
  • Loading branch information...
1 parent 0ff23d8 commit e449d7626dc3b6918578b3052bd9aebfd8cafdae @lsegal committed May 1, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 templates/default/tags/html/option.erb
@@ -14,7 +14,9 @@
<%= tag.pair.defaults.map {|t| "<tt>#{h t}</tt>" }.join(", ") %>
<% end %>
</span>
- <%= "&mdash; " + htmlify_line(tag.pair.text) if tag.pair.text %>
+ <% if tag.pair.text && tag.pair.text =~ /\S/ %>
+ &mdash; <%= htmlify_line(tag.pair.text) %>
+ <% end %>
</li>
<% end %>
</ul>

0 comments on commit e449d76

Please sign in to comment.