Skip to content

Commit 6f6bb05

Browse files
committed
then(success, fail)
1 parent e2a7427 commit 6f6bb05

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/alt/store/StoreMixin.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,10 @@ const StoreMixin = {
6565
loadCounter += 1
6666
/* istanbul ignore else */
6767
if (spec.loading) spec.loading(intercept(null, spec.loading, args))
68-
return spec.remote(state, ...args)
69-
.catch(makeActionHandler(spec.error, 1))
70-
.then(makeActionHandler(spec.success))
68+
return spec.remote(state, ...args).then(
69+
makeActionHandler(spec.success),
70+
makeActionHandler(spec.error, 1)
71+
)
7172
} else {
7273
// otherwise emit the change now
7374
this.emitChange()

0 commit comments

Comments
 (0)