tab bar: Remove unused markup.

The only time we set the `home` flag to true
is when it's the last (and only) item in the
list, in which case we flip `hash` to false
at the end of `make_tab_data()`.

So the section of code where both `home` and
`flag` were true is dead code.

Also, we can use `else` instead of `unless`.
This commit is contained in:
Steve Howell 2019-01-30 20:40:58 +00:00 committed by Tim Abbott
parent 9986e41999
commit 090227e809
1 changed files with 2 additions and 7 deletions

View File

@ -6,18 +6,13 @@
{{/if}}
{{! Most tabs are links, but some are not since we don't have a narrow for them (e.g. Search) }}
{{#if hash}}
{{#if home}}
<a href="{{hash}}" title="{{t 'All messages' }} (Esc)"><i class="fa fa-home" aria-hidden="true"></i></a>
{{else}}
<a href="{{hash}}">{{title}}</a>
{{/if}}
{{else}}
{{#if home}}
<i class="fa fa-home" aria-hidden="true"></i>
{{/if}}
{{#unless home}}
{{else}}
{{title}}
{{/unless}}
{{/if}}
{{/if}}
</li>
{{/each}}