Skip to content

Commit

Permalink
Merge pull request #13416 from influxdata/fix-cloud-logout
Browse files Browse the repository at this point in the history
Fix logout for cloud, use environment variable
  • Loading branch information
bthesorceror authored Apr 15, 2019
2 parents 65cbc78 + 3ecf687 commit 4315daf
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions ui/src/me/components/LogoutButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,23 @@ import {Link} from 'react-router'

// Components
import {Button, ComponentSize} from '@influxdata/clockface'
import CloudExclude from 'src/shared/components/cloud/CloudExclude'
import CloudInclude from 'src/shared/components/cloud/CloudExclude'
import {CLOUD_SIGNOUT_URL} from 'src/shared/constants'

const LogoutButton: SFC = () => (
<Link to="/logout">
<Button text="Logout" size={ComponentSize.ExtraSmall} />
</Link>
<>
<CloudExclude>
<Link to="/logout">
<Button text="Logout" size={ComponentSize.ExtraSmall} />
</Link>
</CloudExclude>
<CloudInclude>
<a href={CLOUD_SIGNOUT_URL}>
<Button text="Logout" size={ComponentSize.ExtraSmall} />
</a>
</CloudInclude>
</>
)

export default LogoutButton

0 comments on commit 4315daf

Please sign in to comment.