mirror of
https://github.com/flarum/framework.git
synced 2024-11-24 23:17:47 +08:00
Fix 0s in notification dropdown
By casting the length int to a bool, if there are no badges, we don't display a 0. It seems that mithril will render integers, but not booleans. Fixes https://github.com/flarum/QualityAssurance/issues/28
This commit is contained in:
parent
8ffeac4315
commit
d1e987a240
|
@ -73,7 +73,7 @@ export default class NotificationList extends Component {
|
|||
<div className="NotificationGroup">
|
||||
{group.discussion ? (
|
||||
<Link className="NotificationGroup-header" href={app.route.discussion(group.discussion)}>
|
||||
{badges && badges.length && <ul className="NotificationGroup-badges badges">{listItems(badges)}</ul>}
|
||||
{badges && !!badges.length && <ul className="NotificationGroup-badges badges">{listItems(badges)}</ul>}
|
||||
<span>{group.discussion.title()}</span>
|
||||
</Link>
|
||||
) : (
|
||||
|
|
Loading…
Reference in New Issue
Block a user