Addressed some earlier diff comments

Summary: Async processed review feedback from stack D31474919 (cfd44b592a) e.o. (decapitate)

Reviewed By: passy

Differential Revision: D31608309

fbshipit-source-id: 536b3c9350f7acc40530000ecf5e46d5b074d50f
This commit is contained in:
Michel Weststrate
2021-10-14 03:16:38 -07:00
committed by Facebook GitHub Bot
parent f307566318
commit f43ff73591
5 changed files with 44 additions and 39 deletions

View File

@@ -10,7 +10,7 @@
import React from 'react';
import {State, Store} from '../reducers/index';
import {Logger} from 'flipper-common';
import {FlipperServerImpl, setFlipperServerConfig} from 'flipper-server-core';
import {FlipperServerImpl} from 'flipper-server-core';
import {selectClient} from '../reducers/connections';
import Client from '../Client';
import {notification} from 'antd';
@@ -24,17 +24,20 @@ import constants from '../fb-stubs/constants';
export default async (store: Store, logger: Logger) => {
const {enableAndroid, androidHome, idbPath, enableIOS, enablePhysicalIOS} =
store.getState().settingsState;
setFlipperServerConfig({
enableAndroid,
androidHome,
idbPath,
enableIOS,
enablePhysicalIOS,
staticPath: getStaticPath(),
tmpPath: getAppTempPath(),
validWebSocketOrigins: constants.VALID_WEB_SOCKET_REQUEST_ORIGIN_PREFIXES,
});
const server = new FlipperServerImpl(logger);
const server = new FlipperServerImpl(
{
enableAndroid,
androidHome,
idbPath,
enableIOS,
enablePhysicalIOS,
staticPath: getStaticPath(),
tmpPath: getAppTempPath(),
validWebSocketOrigins: constants.VALID_WEB_SOCKET_REQUEST_ORIGIN_PREFIXES,
},
logger,
);
store.dispatch({
type: 'SET_FLIPPER_SERVER',