Skip to content

Commit

Permalink
[chores] Change password: SAML/Social login minor improvement #338
Browse files Browse the repository at this point in the history
Related to #338
  • Loading branch information
nemesifier committed Aug 28, 2021
1 parent be29432 commit 0602d89
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions client/components/password-change/password-change.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,7 @@ export default class PasswordChange extends React.Component {
render() {
const {passwordChange, orgSlug, userData} = this.props;
const {errors, newPassword1, newPassword2, hidePassword} = this.state;
if (
userData &&
(userData.method === "saml" || userData.method === "social_login")
)
if (userData && ["saml", "social_login"].includes(userData.method))
return <Redirect to={`/${orgSlug}/status`} />;
return (
<div className="container content" id="password-change">
Expand Down

0 comments on commit 0602d89

Please sign in to comment.