Closed michaelKurowski closed 6 years ago
In redux (react also), we cannot mutate the state directly. Instead of, we should give the new iteration of the state, wchich is merged to the previous one. So- this function return action with new state data (modifed), which will be merged in the reducer.
okay
https://github.com/Lukasz-Semik/cash-organizer/blob/80172dbca7300976928c065acc55a32c57a762f0/app/src/actions/dataActions.js#L179-L183
The name of this function indicates that it edits shooping list, but looks like it just returns an object. There are multiple such cases in this file. Please rename the functions, their names should describe what they really do.