Skip to content

Commit 96166c8

Browse files
committed
adjusting for state no longer needed in dispatch
1 parent 5e1bdf3 commit 96166c8

File tree

3 files changed

+3
-6
lines changed

3 files changed

+3
-6
lines changed

dash/dash-renderer/src/actions/callbacks.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -336,8 +336,7 @@ async function handleClientside(
336336

337337
function updateComponent(component_id: any, props: any, cb: ICallbackPayload) {
338338
return function (dispatch: any, getState: any) {
339-
const _state = getState();
340-
const {paths, config} = _state;
339+
const {paths, config} = getState();
341340
const componentPath = getPath(paths, component_id);
342341
if (!componentPath) {
343342
if (!config.suppress_callback_exceptions) {

dash/dash-renderer/src/observers/executedCallbacks.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,7 @@ const observer: IStoreObserverDefinition<IStoreState> = {
4545
} = getState();
4646

4747
function applyProps(id: any, updatedProps: any) {
48-
const _state = getState();
49-
const {layout, paths} = _state;
48+
const {layout, paths} = getState();
5049
const itempath = getPath(paths, id);
5150
if (!itempath) {
5251
return false;

dash/dash-renderer/src/utils/clientsideFunctions.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@ function set_props(
1616
for (let y = 0; y < ds.length; y++) {
1717
const {dispatch, getState} = ds[y];
1818
let componentPath;
19-
const _state = getState();
20-
const {paths} = _state;
19+
const {paths} = getState();
2120
if (!Array.isArray(idOrPath)) {
2221
componentPath = getPath(paths, idOrPath);
2322
} else {

0 commit comments

Comments
 (0)