Skip to content

Commit

Permalink
feat: return array method result
Browse files Browse the repository at this point in the history
BREAKING CHANGE: array methods now return a value
  • Loading branch information
kouts committed May 17, 2021
1 parent 04a1ece commit d306177
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pathStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const createPathStore = (state) => {
if (!isArray(arr)) {
throw Error('Argument must be an array.')
}
arr[method](...args)
return arr[method](...args)
}
return Object.assign(acc, { [method]: fn })
}, {})
Expand Down

0 comments on commit d306177

Please sign in to comment.