From 36f2596a9e6fb954be7829ea311655daef412f06 Mon Sep 17 00:00:00 2001 From: Mathias Biilmann Christensen Date: Tue, 5 Sep 2017 14:07:56 -0700 Subject: [PATCH] Use netlify identity widget for auth if present --- src/backends/netlify-auth/AuthenticationPage.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/backends/netlify-auth/AuthenticationPage.js b/src/backends/netlify-auth/AuthenticationPage.js index d23aee69..5a5791c4 100644 --- a/src/backends/netlify-auth/AuthenticationPage.js +++ b/src/backends/netlify-auth/AuthenticationPage.js @@ -8,8 +8,6 @@ import styles from "./AuthenticationPage.css"; export default class AuthenticationPage extends React.Component { constructor(props) { super(props); - this.identity = window.netlifyIdentity; - this.state = {user: this.identity && this.identity.gotrue && this.identity.gotrue.currentUser()}; } componentDidMount() { @@ -42,7 +40,7 @@ export default class AuthenticationPage extends React.Component { const { email, password } = this.state; const errors = {}; if (!email) { - errors.email = 'Make sure to enter your email.'; + errors.email = 'Make sure to enter your user name'; } if (!password) { errors.password = 'Please enter your password.';