mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-12-02 06:11:03 +00:00
After signup, redirect to communities page.
This commit is contained in:
parent
a9d2cbb7f9
commit
2cad62b5e3
1 changed files with 8 additions and 1 deletions
|
@ -188,13 +188,20 @@ export class Login extends Component<any, State> {
|
||||||
this.setState(this.state);
|
this.setState(this.state);
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
if (op == UserOperation.Register || op == UserOperation.Login) {
|
if (op == UserOperation.Login) {
|
||||||
this.state.loginLoading = false;
|
this.state.loginLoading = false;
|
||||||
this.state.registerLoading = false;
|
this.state.registerLoading = false;
|
||||||
let res: LoginResponse = msg;
|
let res: LoginResponse = msg;
|
||||||
UserService.Instance.login(res);
|
UserService.Instance.login(res);
|
||||||
this.props.history.push('/');
|
this.props.history.push('/');
|
||||||
|
} else if (op == UserOperation.Register) {
|
||||||
|
this.state.loginLoading = false;
|
||||||
|
this.state.registerLoading = false;
|
||||||
|
let res: LoginResponse = msg;
|
||||||
|
UserService.Instance.login(res);
|
||||||
|
this.props.history.push('/communities');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue