mirror of
https://github.com/apache/superset.git
synced 2024-09-17 11:09:47 -04:00
Taking out object spread operator (#1311)
* Changed eslint channel in codeclimate.yml for object spread * Revert "Changed eslint channel in codeclimate.yml for object spread" This reverts commit b9deb8ce84478f9c8f48ca7d41662e7222f40376. * Took out the object spread operator
This commit is contained in:
parent
451860afca
commit
b785d27241
@ -11,10 +11,11 @@ const setFormInViz = function (state, action) {
|
||||
const setVizInState = function (state, action) {
|
||||
switch (action.type) {
|
||||
case actions.SET_FORM_DATA:
|
||||
return {
|
||||
...state,
|
||||
formData: setFormInViz(state.formData, action),
|
||||
};
|
||||
return Object.assign(
|
||||
{},
|
||||
state,
|
||||
{ formData: setFormInViz(state.formData, action) }
|
||||
);
|
||||
default:
|
||||
return state;
|
||||
}
|
||||
@ -74,10 +75,11 @@ export const exploreReducer = function (state, action) {
|
||||
return Object.assign({}, state, { datasourceType: action.datasourceType });
|
||||
},
|
||||
[actions.SET_FORM_DATA]() {
|
||||
return {
|
||||
...state,
|
||||
viz: setVizInState(state.viz, action),
|
||||
};
|
||||
return Object.assign(
|
||||
{},
|
||||
state,
|
||||
{ viz: setVizInState(state.viz, action) }
|
||||
);
|
||||
},
|
||||
};
|
||||
if (action.type in actionHandlers) {
|
||||
|
Loading…
Reference in New Issue
Block a user