From be73b8bea8255233752808f2fb0f8f72c2cb573a Mon Sep 17 00:00:00 2001 From: Juan Tejada Date: Thu, 28 Jan 2016 19:52:11 -0800 Subject: [PATCH] fix(account-switcher): Don't display "All Accounts" when only 1 account --- .../account-sidebar/lib/components/account-switcher.cjsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/internal_packages/account-sidebar/lib/components/account-switcher.cjsx b/internal_packages/account-sidebar/lib/components/account-switcher.cjsx index 40843e043..7ca88d043 100644 --- a/internal_packages/account-sidebar/lib/components/account-switcher.cjsx +++ b/internal_packages/account-sidebar/lib/components/account-switcher.cjsx @@ -139,7 +139,10 @@ class AccountSwitcher extends React.Component classnames = "" classnames += "open" if @state.showing selected = @_selectedItem() - items = [@_makeItem()].concat @props.accounts.map(@_makeItem) + if @props.accounts.length is 1 + items = @props.accounts.map(@_makeItem) + else + items = [@_makeItem()].concat @props.accounts.map(@_makeItem)