Add to queue random functional
This commit is contained in:
@ -257,10 +257,9 @@ export function removeFromIndex(index_name, key, new_key = null) {
|
||||
};
|
||||
}
|
||||
|
||||
export function viewDataLoaded(name, data) {
|
||||
export function viewDataLoaded(data) {
|
||||
return {
|
||||
type: 'VIEW_DATA_LOADED',
|
||||
name,
|
||||
data,
|
||||
};
|
||||
}
|
||||
|
||||
@ -199,12 +199,11 @@ export default function reducer(core = {}, action) {
|
||||
return { ...core, genres: action.genres };
|
||||
|
||||
case 'VIEW_DATA_LOADED':
|
||||
console.log(action);
|
||||
return {
|
||||
...core,
|
||||
view: {
|
||||
...(core.view ? core.view : {}),
|
||||
[action.name]: action.data,
|
||||
...action.data,
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user