Skip to content

Commit

Permalink
set jupyterHubAuthenticator explicitly even for default values (#2235)
Browse files Browse the repository at this point in the history
  • Loading branch information
kunmingg authored and k8s-ci-robot committed Jan 8, 2019
1 parent 628cd6d commit efdbb1b
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions components/gcp-click-to-deploy/src/DeployForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,6 @@ export default class DeployForm extends React.Component<any, DeployFormState> {

const state = this.state;
const email = await Gapi.getSignedInEmail();
let iapIdx = 0;
for (let i = 0, len = this._configSpec.defaultApp.parameters.length; i < len; i++) {
const p = this._configSpec.defaultApp.parameters[i];
if (p.name === 'ipName') {
Expand All @@ -303,12 +302,11 @@ export default class DeployForm extends React.Component<any, DeployFormState> {
}

if (p.name === 'jupyterHubAuthenticator') {
iapIdx = i;
if (this.state.clientId === '' || this.state.clientSecret === '') {
p.value = 'null';
}
}
}
if (this.state.clientId === '' || this.state.clientSecret === '') {
this._configSpec.defaultApp.parameters.splice(iapIdx, 1);
}
this._configSpec.defaultApp.registries[0].version = this.state.kfversion;

return this._configSpec;
Expand Down

0 comments on commit efdbb1b

Please sign in to comment.