You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

functions.js 701B

1234567891011121314151617181920212223
  1. // @flow
  2. import { getCurrentConference } from '../base/conference';
  3. /**
  4. * Approves (lets in) or rejects a knocking participant.
  5. *
  6. * @param {Function} getState - Function to get the Redux state.
  7. * @param {string} id - The id of the knocking participant.
  8. * @param {boolean} approved - True if the participant is approved, false otherwise.
  9. * @returns {Function}
  10. */
  11. export function setKnockingParticipantApproval(getState: Function, id: string, approved: boolean) {
  12. const conference = getCurrentConference(getState());
  13. if (conference) {
  14. if (approved) {
  15. conference.lobbyApproveAccess(id);
  16. } else {
  17. conference.lobbyDenyAccess(id);
  18. }
  19. }
  20. }