mirror of
https://github.com/apache/superset.git
synced 2026-04-20 16:44:46 +00:00
Re-enable rule prefer-destructuring (only for objects) (#10867)
This commit is contained in:
committed by
GitHub
parent
c51168a30a
commit
352e8a1afd
@@ -375,7 +375,7 @@ export default function sqlLabReducer(state = {}, action) {
|
||||
},
|
||||
[actions.MIGRATE_QUERY_EDITOR]() {
|
||||
// remove migrated query editor from localStorage
|
||||
const sqlLab = JSON.parse(localStorage.getItem('redux')).sqlLab;
|
||||
const { sqlLab } = JSON.parse(localStorage.getItem('redux'));
|
||||
sqlLab.queryEditors = sqlLab.queryEditors.filter(
|
||||
qe => qe.id !== action.oldQueryEditor.id,
|
||||
);
|
||||
@@ -390,7 +390,7 @@ export default function sqlLabReducer(state = {}, action) {
|
||||
},
|
||||
[actions.MIGRATE_TABLE]() {
|
||||
// remove migrated table from localStorage
|
||||
const sqlLab = JSON.parse(localStorage.getItem('redux')).sqlLab;
|
||||
const { sqlLab } = JSON.parse(localStorage.getItem('redux'));
|
||||
sqlLab.tables = sqlLab.tables.filter(
|
||||
table => table.id !== action.oldTable.id,
|
||||
);
|
||||
@@ -405,7 +405,7 @@ export default function sqlLabReducer(state = {}, action) {
|
||||
},
|
||||
[actions.MIGRATE_TAB_HISTORY]() {
|
||||
// remove migrated tab from localStorage tabHistory
|
||||
const sqlLab = JSON.parse(localStorage.getItem('redux')).sqlLab;
|
||||
const { sqlLab } = JSON.parse(localStorage.getItem('redux'));
|
||||
sqlLab.tabHistory = sqlLab.tabHistory.filter(
|
||||
tabId => tabId !== action.oldId,
|
||||
);
|
||||
@@ -492,7 +492,7 @@ export default function sqlLabReducer(state = {}, action) {
|
||||
let newQueries = { ...state.queries };
|
||||
// Fetch the updates to the queries present in the store.
|
||||
let change = false;
|
||||
let queriesLastUpdate = state.queriesLastUpdate;
|
||||
let { queriesLastUpdate } = state;
|
||||
for (const id in action.alteredQueries) {
|
||||
const changedQuery = action.alteredQueries[id];
|
||||
if (
|
||||
|
||||
Reference in New Issue
Block a user