diff --git a/assets/src/js/components/SiteSwitcher.js b/assets/src/js/components/SiteSwitcher.js index 295356d..6aa3cc5 100644 --- a/assets/src/js/components/SiteSwitcher.js +++ b/assets/src/js/components/SiteSwitcher.js @@ -32,15 +32,18 @@ class SiteSwitcher extends Component { } render(props, state) { - let siteNodes = props.sites.map((s) => (
  • {s.name}
  • )) - let addSiteNode = props.showAdd ? (
  • + Add another site
  • ) : ''; + // show nothing if there is only 1 site and no option to add additional sites + if(!props.showAdd && props.sites.length == 1) { + return ''; + } + // otherwise, render list of sites + add button return (
  • {props.selectedSite.name}
  • )