fix: menu shows a 0 when there are not settings (#11009)

This commit is contained in:
ʈᵃᵢ 2020-09-23 09:22:45 -07:00 committed by GitHub
parent ba009b7c09
commit 345fe07d64
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -187,7 +187,7 @@ export function Menu({
</Nav> </Nav>
<Nav className="navbar-right"> <Nav className="navbar-right">
{!navbarRight.user_is_anonymous && <NewMenu />} {!navbarRight.user_is_anonymous && <NewMenu />}
{settings && settings.length && ( {settings && settings.length > 0 && (
<NavDropdown id="settings-dropdown" title="Settings"> <NavDropdown id="settings-dropdown" title="Settings">
{flatSettings.map((section, index) => { {flatSettings.map((section, index) => {
if (section === '-') { if (section === '-') {