Skip to content

Commit 43a49f3

Browse files
committed
fixup! fixup! add forgot password in login
1 parent 3667210 commit 43a49f3

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/app/components/Authentication/Login.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ import { Col, Row } from 'react-bootstrap';
1111
import { Redirect } from 'react-router-dom';
1212
import { API_BASE_URL } from '../../../config/config';
1313

14+
export enum OAUTH_ROUTES {
15+
GOOGLE = 'login/google',
16+
GITHUB = 'login/github',
17+
}
1418
export class Login extends React.Component<LoginInterfaces.Props, LoginInterfaces.State> {
1519
private loginRef = React.createRef<HTMLFormElement>();
1620
private forgotPasswordRef = React.createRef<HTMLFormElement>();
@@ -81,7 +85,7 @@ export class Login extends React.Component<LoginInterfaces.Props, LoginInterface
8185
<div className={classnames('container px-0 justify-content-center', styles.loginForm)}>
8286
<Row
8387
onClick={(e) => {
84-
window.location.href = `${API_BASE_URL}${Routes.GOOGLE_OAUTH}`;
88+
window.location.href = `${API_BASE_URL}${OAUTH_ROUTES.GOOGLE}`;
8589
}}
8690
className={classnames(
8791
styles['google-btn'],
@@ -97,7 +101,7 @@ export class Login extends React.Component<LoginInterfaces.Props, LoginInterface
97101
</Row>
98102
<Row
99103
onClick={(e) => {
100-
window.location.href = `${API_BASE_URL}${Routes.GITHUB_OAUTH}`;
104+
window.location.href = `${API_BASE_URL}${OAUTH_ROUTES.GITHUB}`;
101105
}}
102106
className={classnames(
103107
'justify-content-center',

0 commit comments

Comments
 (0)