Use more selectors

This commit is contained in:
Chi Vinh Le
2018-02-13 16:00:03 +01:00
parent c140a62822
commit 0f69df26f6
6 changed files with 16 additions and 11 deletions
@@ -4,9 +4,9 @@ import { Button } from 'plugin-api/beta/client/components/ui';
import { t } from 'plugin-api/beta/client/services';
import styles from './SignInButton.css';
const SignInButton = ({ currentUser, showSignInDialog }) => (
const SignInButton = ({ isLoggedIn, showSignInDialog }) => (
<div className="talk-stream-auth-sign-in-button">
{!currentUser ? (
{!isLoggedIn ? (
<Button
id="coralSignInButton"
className={styles.button}
@@ -20,7 +20,7 @@ const SignInButton = ({ currentUser, showSignInDialog }) => (
);
SignInButton.propTypes = {
currentUser: PropTypes.object,
isLoggedIn: PropTypes.bool,
showSignInDialog: PropTypes.func,
};