mirror of
https://github.com/ansible/awx.git
synced 2026-02-12 07:04:45 -03:30
handle null error response
This commit is contained in:
@@ -48,7 +48,7 @@ class AWXLogin extends Component {
|
||||
try {
|
||||
await api.login(username, password);
|
||||
} catch (error) {
|
||||
if (error.response.status === 401) {
|
||||
if (error.response && error.response.status === 401) {
|
||||
this.setState({ isInputValid: false });
|
||||
}
|
||||
} finally {
|
||||
|
||||
Reference in New Issue
Block a user