<commit_before>import { Module } from '../../lib/di';
import callDirections from '../../enums/callDirections';
import RcModule from '../../lib/RcModule';
import actionTypes from './actionTypes';
import partyStatusCode from './partyStatusCode';
import conferenceRole from './conferenceRole';
import getConferenceCallReducer from './getConferenceCallReducer';
import proxify from '../../lib/proxy/proxify';
import permissionsMessages from '../RolesAndPermissions/permissionsMessages';
import conferenceErrors from './conferenceCallErrors';
import { isConferenceSession } from '../Webphone/webphoneHelper';
// import webphoneErrors from '../Webphone/webphoneErrors';
import ensureExist from '../../lib/ensureExist';
// import sleep from '../../lib/sleep';
import callingModes from '../CallingSettings/callingModes';

const DEFAULT_TIMEOUT = 30000;// time out for conferencing session being accepted.
const DEFAULT_TTL = 5000;// timer to update the conference information
const MAXIMUM_CAPACITY = 10;


function ascendSortParties(parties) {
  return parties
    .filter(party => party.conferenceRole.toLowerCase() !== conferenceRole.host)
    .sort((last, next) => +last.id.split('-')[1] - (+next.id.split('-')[1]));
}

/**
 * @class
 * @description ConferenceCall managing module
 */
@Module({
  deps: [
    'Auth',
    'Alert',
    'Call',
    'CallingSettings',
    'Client',
    'Webphone',
    'RolesAndPermissions',
    {
      dep: 'ContactMatcher',
      optional: true
    },
    { dep: 'ConnectivityMonitor', optional: true },
    {
      dep: 'ConferenceCallOptions',
      optional: true
    },
  ]
})
export default class ConferenceCall extends RcModule {
  /**
   * @constructor
   * @param {Object} params - params object
   * @param {RegionSettings} params.regionSettings - regionSettings module instance
   * @param {Client} params.client - client module instance
   */
  constructor({
    auth,
    alert,
    call,<commit_msg>refactor(ConnectivityMonitor): make ConnectivityMonitor as necessary dependency<commit_after>import { Module } from '../../lib/di';
import callDirections from '../../enums/callDirections';
import RcModule from '../../lib/RcModule';
import actionTypes from './actionTypes';
import partyStatusCode from './partyStatusCode';
import conferenceRole from './conferenceRole';
import getConferenceCallReducer from './getConferenceCallReducer';
import proxify from '../../lib/proxy/proxify';
import permissionsMessages from '../RolesAndPermissions/permissionsMessages';
import conferenceErrors from './conferenceCallErrors';
import { isConferenceSession } from '../Webphone/webphoneHelper';
// import webphoneErrors from '../Webphone/webphoneErrors';
import ensureExist from '../../lib/ensureExist';
// import sleep from '../../lib/sleep';
import callingModes from '../CallingSettings/callingModes';

const DEFAULT_TIMEOUT = 30000;// time out for conferencing session being accepted.
const DEFAULT_TTL = 5000;// timer to update the conference information
const MAXIMUM_CAPACITY = 10;


function ascendSortParties(parties) {
  return parties
    .filter(party => party.conferenceRole.toLowerCase() !== conferenceRole.host)
    .sort((last, next) => +last.id.split('-')[1] - (+next.id.split('-')[1]));
}

/**
 * @class
 * @description ConferenceCall managing module
 */
@Module({
  deps: [
    'Auth',
    'Alert',
    'Call',
    'CallingSettings',
    'ConnectivityMonitor',
    'Client',
    'Webphone',
    'RolesAndPermissions',
    {
      dep: 'ContactMatcher',
      optional: true
    },
<<<<<<< HEAD
    { dep: 'ConnectivityMonitor', optional: true },
=======
    {
      dep: 'Webphone',
      optional: true
    },
>>>>>>> refactor(ConnectivityMonitor): make ConnectivityMonitor as necessary dependency
    {
      dep: 'ConferenceCallOptions',
      optional: true
    },
  ]
})
export default class ConferenceCall extends RcModule {
  /**
   * @constructor
   * @param {Object} params - params object
   * @param {RegionSettings} params.regionSettings - regionSettings module instance
   * @param {Client} params.client - client module instance
   */
  constructor({
    auth,
    alert,
    call,
{'fraction_non_alphanumeric': 0.14296063752716734, 'fraction_numerical': 0.0062786766481526205, 'mean_word_length': 3.81068524970964, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 14, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5935748', 'n_tokens_mistral': 1167, 'n_tokens_neox': 1158, 'n_words': 310}