Skip to content

Commit e6f5c81

Browse files
committed
Simplify link proc in classes sidebar view
The current usage always respects the `klass.display?` value, so we don't need to pass it to the proc.
1 parent f8f4215 commit e6f5c81

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/rdoc/generator/template/darkfish/_sidebar_classes.rhtml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33

44
<%-
55
all_classes = group_classes_by_namespace_for_sidebar(@classes)
6-
link = proc do |index_klass, display = index_klass.display?|
7-
if display
6+
link = proc do |index_klass|
7+
if index_klass.display?
88
-%><code><a href="<%= rel_prefix %>/<%= index_klass.path %>"><%= index_klass.name %></a></code><%-
99
else
1010
-%><code><%= index_klass.name %></code><%-
@@ -20,7 +20,7 @@
2020
<%- traverse.call(children) -%>
2121
</ul></details>
2222
<%- elsif index_klass.display? -%>
23-
<li><% link.call(index_klass, true) %>
23+
<li><% link.call(index_klass) %>
2424
<%- end -%>
2525
<%- end -%>
2626
<%- end -%>

0 commit comments

Comments
 (0)