Skip to content

Commit 8279bc2

Browse files
committed
fixed up the 0 allowed post types case for the category post types view just in case
1 parent 8f2facb commit 8279bc2

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

app/views/categories/post_types.html.erb

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
1-
<h1>What kind of post?</h1>
1+
<% header_title = @post_types.any? ? 'What kind of post?' : 'No allowed post types'
2+
header_subtitle = @post_types.any? \
3+
? 'This category has more than one type of post available. Pick a post type to get started.'
4+
: 'This category does not have any post types available.'
5+
%>
6+
7+
<h1><%= header_title %></h1>
28
<p class="has-font-size-larger has-color-tertiary-500">
3-
This category has more than one type of post available. Pick a post type to get started.
9+
<%= header_subtitle %>
410
</p>
511

612
<% @post_types.each do |pt| %>

0 commit comments

Comments
 (0)