Fix event reemitting types
The callback args for reemitting will change to an array including the originals emitter.
This commit is contained in:
@@ -142,6 +142,7 @@ import {
|
|||||||
import { Publisher } from "./localMember/Publisher.ts";
|
import { Publisher } from "./localMember/Publisher.ts";
|
||||||
import { type Connection } from "./remoteMembers/Connection.ts";
|
import { type Connection } from "./remoteMembers/Connection.ts";
|
||||||
import { createLayoutModeSwitch } from "./LayoutSwitch.ts";
|
import { createLayoutModeSwitch } from "./LayoutSwitch.ts";
|
||||||
|
import { IMembershipManager } from "matrix-js-sdk/lib/matrixrtc/IMembershipManager";
|
||||||
|
|
||||||
const logger = rootLogger.getChild("[CallViewModel]");
|
const logger = rootLogger.getChild("[CallViewModel]");
|
||||||
//TODO
|
//TODO
|
||||||
@@ -445,8 +446,17 @@ export function createCallViewModel$(
|
|||||||
fromEvent(
|
fromEvent(
|
||||||
matrixRTCSession,
|
matrixRTCSession,
|
||||||
MembershipManagerEvent.DelayIdChanged,
|
MembershipManagerEvent.DelayIdChanged,
|
||||||
) as Observable<string | undefined>
|
// The type of reemitted event includes the original emitted as the second arg.
|
||||||
).pipe(map((v) => v ?? null)),
|
) as Observable<[string | undefined, IMembershipManager]>
|
||||||
|
).pipe(
|
||||||
|
map(([delayId]) => {
|
||||||
|
logger.debug(
|
||||||
|
"DelayId change emitted from matrixRTCSession: ",
|
||||||
|
delayId,
|
||||||
|
);
|
||||||
|
return delayId ?? null;
|
||||||
|
}),
|
||||||
|
),
|
||||||
matrixRTCSession.delayId ?? null,
|
matrixRTCSession.delayId ?? null,
|
||||||
),
|
),
|
||||||
roomId: matrixRoom.roomId,
|
roomId: matrixRoom.roomId,
|
||||||
|
|||||||
@@ -177,8 +177,11 @@ export const createLocalTransport$ = ({
|
|||||||
switchMap(([customUrl, delayId, forceEndpoint]) => {
|
switchMap(([customUrl, delayId, forceEndpoint]) => {
|
||||||
logger.info(
|
logger.info(
|
||||||
"Creating preferred transport based on: ",
|
"Creating preferred transport based on: ",
|
||||||
|
"customUrl: ",
|
||||||
customUrl,
|
customUrl,
|
||||||
|
"delayId: ",
|
||||||
delayId,
|
delayId,
|
||||||
|
"forceEndpoint: ",
|
||||||
forceEndpoint,
|
forceEndpoint,
|
||||||
);
|
);
|
||||||
return from(
|
return from(
|
||||||
|
|||||||
@@ -11453,8 +11453,8 @@ __metadata:
|
|||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"matrix-js-sdk@matrix-org/matrix-js-sdk#develop":
|
"matrix-js-sdk@matrix-org/matrix-js-sdk#develop":
|
||||||
version: 39.4.0
|
version: 40.0.0
|
||||||
resolution: "matrix-js-sdk@https://github.com/matrix-org/matrix-js-sdk.git#commit=4d0d32307eb4f1ce1fb65080fcca704f5bdedc31"
|
resolution: "matrix-js-sdk@https://github.com/matrix-org/matrix-js-sdk.git#commit=899cdb0e1da4933d3eaf4c7337c1846e1ec8174c"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": "npm:^7.12.5"
|
"@babel/runtime": "npm:^7.12.5"
|
||||||
"@matrix-org/matrix-sdk-crypto-wasm": "npm:^17.0.0"
|
"@matrix-org/matrix-sdk-crypto-wasm": "npm:^17.0.0"
|
||||||
@@ -11470,7 +11470,7 @@ __metadata:
|
|||||||
sdp-transform: "npm:^3.0.0"
|
sdp-transform: "npm:^3.0.0"
|
||||||
unhomoglyph: "npm:^1.0.6"
|
unhomoglyph: "npm:^1.0.6"
|
||||||
uuid: "npm:13"
|
uuid: "npm:13"
|
||||||
checksum: 10c0/59c9d81ccf823584dc783502cb5c928562e3490c63f5ce98ee3232a603545d6278e90dc951c1fd0bae2792ba732ec5171e03596fd396bb2150d596cebb7fbac9
|
checksum: 10c0/2476eb0bfed0b74fe5dcae25022a28d53d69297570d93f6121893246a9fd22452c48477fa605e99f25405f0249b14ffcaed0fd7cbf3318ad4cee20458689f40e
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user