Merge pull request #2675 from jryans/default-hs-to-form

Skip server details on registration with a default HS
This commit is contained in:
J. Ryan Stinnett 2019-02-22 10:19:53 +00:00 committed by GitHub
commit ca5c7b03d3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 2 deletions

View file

@ -60,6 +60,7 @@ module.exports = React.createClass({
customIsUrl: PropTypes.string,
defaultHsUrl: PropTypes.string,
defaultIsUrl: PropTypes.string,
skipServerDetails: PropTypes.bool,
brand: PropTypes.string,
email: PropTypes.string,
// registration shouldn't know or care how login is done.
@ -75,8 +76,10 @@ module.exports = React.createClass({
// (they could come in from the URL params in a
// registration email link)
(this.props.clientSecret && this.props.sessionId) ||
// or if custom URLs aren't allowed, skip them
!customURLsAllowed
// if custom URLs aren't allowed, skip to form
!customURLsAllowed ||
// if other logic says to, skip to form
this.props.skipServerDetails
) {
initialPhase = PHASE_REGISTRATION;
}