fix(rn,lobby) fix lobby not showing up on subsequent tries

We need to make sure to hide it explicitly so the Redux state is in sync
with reality.
pull/11257/head jitsi-meet_7115
Saúl Ibarra Corretgé 3 years ago committed by Saúl Ibarra Corretgé
parent ab91f79448
commit f503bd7352
  1. 15
      react/features/lobby/actions.native.js

@ -1,9 +1,9 @@
// @flow
import { type Dispatch } from 'redux';
import { batch } from 'react-redux';
import { appNavigate } from '../app/actions';
import { hideLobbyScreen, setKnockingState } from './actions.any';
export * from './actions.any';
/**
@ -12,8 +12,11 @@ export * from './actions.any';
* @returns {Function}
*/
export function cancelKnocking() {
return async (dispatch: Dispatch<any>) => {
dispatch(appNavigate(undefined));
return dispatch => {
batch(() => {
dispatch(setKnockingState(false));
dispatch(hideLobbyScreen());
dispatch(appNavigate(undefined));
});
};
}

Loading…
Cancel
Save