Flipper fails to load on Windows because of ifinite PluginContainer component update loop

Summary: Flipper fails to load on Windows because of inifinite update loop in PluginContainer component.

Reviewed By: mweststrate

Differential Revision: D19374611

fbshipit-source-id: f2039c055ffefe508c8cf5bcfcd16fffc97a10b8
This commit is contained in:
Anton Nikolaev
2020-01-14 04:26:52 -08:00
committed by Facebook Github Bot
parent 5fd8db294a
commit b117a36f8a

View File

@@ -142,7 +142,7 @@ class PluginContainer extends PureComponent<Props, State> {
};
idler?: Idler;
pluginBeingProcessed: string = '';
pluginBeingProcessed: string | null = null;
state = {progress: {current: 0, total: 0}};
@@ -169,7 +169,7 @@ class PluginContainer extends PureComponent<Props, State> {
processMessageQueue() {
const {pluginKey, pendingMessages, activePlugin} = this.props;
if (pluginKey !== this.pluginBeingProcessed) {
this.pluginBeingProcessed = pluginKey ?? '';
this.pluginBeingProcessed = pluginKey;
this.cancelCurrentQueue();
this.setState({progress: {current: 0, total: 0}});
if (