diff --git a/src/CallHandler.tsx b/src/CallHandler.tsx index dc2d60db0e..b4e8ae75e6 100644 --- a/src/CallHandler.tsx +++ b/src/CallHandler.tsx @@ -67,9 +67,6 @@ export const PROTOCOL_SIP_NATIVE = 'im.vector.protocol.sip_native'; export const PROTOCOL_SIP_VIRTUAL = 'im.vector.protocol.sip_virtual'; const CHECK_PROTOCOLS_ATTEMPTS = 3; -// Event type for room account data and room creation content used to mark rooms as virtual rooms -// (and store the ID of their native room) -export const VIRTUAL_ROOM_EVENT_TYPE = 'im.vector.is_virtual_room'; enum AudioID { Ring = 'ringAudio', diff --git a/src/VoipUserMapper.ts b/src/VoipUserMapper.ts index cb39d9affb..90f920bc9b 100644 --- a/src/VoipUserMapper.ts +++ b/src/VoipUserMapper.ts @@ -21,7 +21,8 @@ import { EventType } from 'matrix-js-sdk/src/@types/event'; import { ensureVirtualRoomExists, findDMForUser } from './createRoom'; import { MatrixClientPeg } from "./MatrixClientPeg"; import DMRoomMap from "./utils/DMRoomMap"; -import CallHandler, { VIRTUAL_ROOM_EVENT_TYPE } from './CallHandler'; +import CallHandler from './CallHandler'; +import { VIRTUAL_ROOM_EVENT_TYPE } from "./call-types"; // Functions for mapping virtual users & rooms. Currently the only lookup // is sip virtual: there could be others in the future. diff --git a/src/call-types.ts b/src/call-types.ts new file mode 100644 index 0000000000..c12491e102 --- /dev/null +++ b/src/call-types.ts @@ -0,0 +1,19 @@ +/* +Copyright 2022 The Matrix.org Foundation C.I.C. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Event type for room account data and room creation content used to mark rooms as virtual rooms +// (and store the ID of their native room) +export const VIRTUAL_ROOM_EVENT_TYPE = 'im.vector.is_virtual_room'; diff --git a/src/createRoom.ts b/src/createRoom.ts index 91eb1b45e9..92efb9477d 100644 --- a/src/createRoom.ts +++ b/src/createRoom.ts @@ -39,7 +39,7 @@ import DMRoomMap from "./utils/DMRoomMap"; import { getAddressType } from "./UserAddress"; import { getE2EEWellKnown } from "./utils/WellKnownUtils"; import { isJoinedOrNearlyJoined } from "./utils/membership"; -import { VIRTUAL_ROOM_EVENT_TYPE } from "./CallHandler"; +import { VIRTUAL_ROOM_EVENT_TYPE } from "./call-types"; import SpaceStore from "./stores/spaces/SpaceStore"; import { makeSpaceParentEvent } from "./utils/space"; import { VOICE_CHANNEL_MEMBER, addVoiceChannel } from "./utils/VoiceChannelUtils";