Fix alert after the user is logged

If the user enters the wrong password the first time and then login, he
will be prompted with an error.
This commit fixes this behaviour.
This commit is contained in:
Grégoire Delattre 2019-07-18 12:52:10 +02:00
parent 5774ed364e
commit 3bcbd4e992

View File

@ -1,6 +1,6 @@
import { configureAxios, request } from "../requests" import { configureAxios, request } from "../requests"
import { addAlertOk } from "./alerts" import { addAlertOk, dismissAlert } from "./alerts"
import { getManagedPolochons } from "./polochon" import { getManagedPolochons } from "./polochon"
@ -20,6 +20,9 @@ export function loginUser(username, password) {
password: password, password: password,
}, },
), ),
[
() => dismissAlert(),
]
) )
} }