We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ac43ce0 commit b12c91aCopy full SHA for b12c91a
src/getActionTypes.js
@@ -1,5 +1,5 @@
1
-export const SUCCESS_SUFFIX = 'SUCCESS';
2
-export const ERROR_SUFFIX = 'FAIL';
+export const SUCCESS_SUFFIX = '_SUCCESS';
+export const ERROR_SUFFIX = '_FAIL';
3
4
export const getActionTypes = (action, {
5
errorSuffix = ERROR_SUFFIX,
@@ -8,7 +8,7 @@ export const getActionTypes = (action, {
8
let types;
9
if (typeof action.type !== 'undefined') {
10
const { type } = action;
11
- types = [type, `${type}_${successSuffix}`, `${type}_${errorSuffix}`];
+ types = [type, `${type}${successSuffix}`, `${type}${errorSuffix}`];
12
} else if (typeof action.types !== 'undefined') {
13
types = action.types;
14
} else {
0 commit comments