mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-02-23 05:59:28 -06:00
fix: clear loading state if consent or logon received
This commit is contained in:
@@ -32,13 +32,10 @@ function loginReducer(state = {
|
||||
|
||||
case RECEIVE_CONSENT:
|
||||
case RECEIVE_LOGON:
|
||||
if (!action.success) {
|
||||
return Object.assign({}, state, {
|
||||
errors: action.errors ? action.errors : {},
|
||||
loading: ''
|
||||
});
|
||||
}
|
||||
return state;
|
||||
return Object.assign({}, state, {
|
||||
errors: !action.success && action.errors ? action.errors : {},
|
||||
loading: ''
|
||||
});
|
||||
|
||||
case RECEIVE_LOGOFF:
|
||||
return Object.assign({}, state, {
|
||||
|
||||
Reference in New Issue
Block a user