File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
templates/vue-common/store/modules Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -3,20 +3,20 @@ import { getField, updateField } from 'vuex-map-fields';
3
3
import remove from 'lodash/remove' ;
4
4
import SubmissionError from '../../error/SubmissionError' ;
5
5
6
- const initialState = {
6
+ const initialState = ( ) => ( {
7
7
allIds : [ ] ,
8
8
byId : { } ,
9
9
created : null ,
10
10
deleted : null ,
11
- error : '' ,
11
+ error : "" ,
12
12
isLoading : false ,
13
13
resetList : false ,
14
14
selectItems : null ,
15
15
totalItems : 0 ,
16
16
updated : null ,
17
17
view : null ,
18
18
violations : null
19
- } ;
19
+ } ) ;
20
20
21
21
const handleError = ( commit , e ) => {
22
22
commit ( ACTIONS . TOGGLE_LOADING ) ;
@@ -26,7 +26,7 @@ const handleError = (commit, e) => {
26
26
// eslint-disable-next-line
27
27
commit ( ACTIONS . SET_ERROR , e . errors . _error ) ;
28
28
29
- return ;
29
+ return Promise . reject ( e ) ;
30
30
}
31
31
32
32
// eslint-disable-next-line
You can’t perform that action at this time.
0 commit comments