mirror of
https://github.com/ZwareBear/awx.git
synced 2026-03-24 09:43:35 -05:00
Begin using async/await.
This commit is contained in:
@@ -22,6 +22,7 @@ import {
|
||||
import { global_breakpoint_md as breakpointMd } from '@patternfly/react-tokens';
|
||||
|
||||
import api from './api';
|
||||
import { API_LOGOUT } from './endpoints';
|
||||
|
||||
// import About from './components/About';
|
||||
import LogoutButton from './components/LogoutButton';
|
||||
@@ -79,11 +80,9 @@ class App extends React.Component {
|
||||
this.setState({ activeGroup: 'views_group', activeItem: 'views_group_dashboard' });
|
||||
}
|
||||
|
||||
onDevLogout = () => {
|
||||
api.logout()
|
||||
.then(() => {
|
||||
this.setState({ activeGroup: 'views_group', activeItem: 'views_group_dashboard' });
|
||||
});
|
||||
onDevLogout = async () => {
|
||||
await api.BaseGet(API_LOGOUT);
|
||||
this.setState({ activeGroup: 'views_group', activeItem: 'views_group_dashboard' });
|
||||
}
|
||||
|
||||
render () {
|
||||
|
||||
Reference in New Issue
Block a user