Skip to content

Commit 4dc27d0

Browse files
committed
fix prefix @@ being removed
1 parent 85fa641 commit 4dc27d0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ function reduxGraphql(options) {
2727
const { dispatch } = this.props;
2828
return async (...args) => {
2929
dispatch({
30-
type: prefix + options.name |> snakeCase |> toUpper,
30+
type: prefix + (options.name |> snakeCase |> toUpper),
3131
payload: args[0],
3232
});
3333
try {
3434
const result = await mutation(...args);
3535
dispatch({
36-
type: prefix + options.name + '_success' |> snakeCase |> toUpper,
36+
type: prefix + (options.name + '_success' |> snakeCase |> toUpper),
3737
payload: {
3838
result,
3939
args: args[0],
@@ -43,7 +43,7 @@ function reduxGraphql(options) {
4343
}
4444
catch (error) {
4545
dispatch({
46-
type: prefix + options.name + '_fail' |> snakeCase |> toUpper,
46+
type: prefix + (options.name + '_fail' |> snakeCase |> toUpper),
4747
payload: args[0],
4848
meta: { error },
4949
});

0 commit comments

Comments
 (0)