auth and asset setup tweaks

This commit is contained in:
Shawn Erquhart 2017-09-06 09:35:31 -07:00
parent 0b793cbc65
commit 128588fd69
4 changed files with 5 additions and 9 deletions

View File

@ -1,7 +1,6 @@
backend:
name: netlify-auth
auth_url: "/.netlify/identity"
github_proxy_url: "/.netlify/git/github"
name: test-repo
delay: 0.1
media_folder: "assets/uploads"

View File

@ -78,9 +78,6 @@
}
}
</script>
<script type='text/javascript' src='https://d33wubrfki0l68.cloudfront.net/js/1e8330b19f2c7165019dffac65520214da9f0af4/netlify-identity-umd.js'></script>
<script>window.identity = new netlifyIdentity()</script>
</head>
<body>

View File

@ -42,10 +42,10 @@ export default class AuthenticationPage extends React.Component {
const { email, password } = this.state;
const errors = {};
if (!email) {
errors.email = 'Make sure to enter your user name';
errors.email = 'Make sure to enter your email.';
}
if (!password) {
errors.password = 'Please enter your password';
errors.password = 'Please enter your password.';
}
if (Object.keys(errors).length > 0) {

View File

@ -31,7 +31,7 @@ export default class NetlifyAuth extends GitHubBackend {
throw new Error("The NetlifyAuth backend needs an \"github_proxy_url\" in the backend configuration.");
}
this.accept_roles = (config.getIn(["backend", "accept_roles"]) || new List()).toArray();
this.accept_roles = (config.getIn(["backend", "accept_roles"]) || List()).toArray();
const netlifySiteURL = localStorage.getItem("netlifySiteURL");
const APIUrl = getEndpoint(config.getIn(["backend", "auth_url"]), netlifySiteURL);