Use toast instead of alert for authentication errors

This commit is contained in:
navaneeth 2021-04-23 22:05:43 +05:30
parent 8482808b75
commit b141d585df

View file

@ -1,5 +1,6 @@
import React from 'react';
import { authenticationService } from '@/_services';
import { toast } from 'react-toastify';
class LoginPage extends React.Component {
constructor(props) {
@ -27,7 +28,7 @@ class LoginPage extends React.Component {
this.props.history.push(from);
},
error => {
alert('Invalid username or password');
toast.error('Invalid username or password', { hideProgressBar: true, position: "top-center" });
}
);
}