File tree 4 files changed +18
-9
lines changed
4 files changed +18
-9
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ ' livekit-client ' : patch
3
+ ---
4
+
5
+ Fix duplicate ParticipantPermissionsChanged updates for the local participant
Original file line number Diff line number Diff line change 1
1
//@ts -ignore
2
2
import E2EEWorker from '../src/e2ee/worker/e2ee.worker?worker' ;
3
+ import type {
4
+ ChatMessage ,
5
+ RoomConnectOptions ,
6
+ RoomOptions ,
7
+ ScalabilityMode ,
8
+ SimulationScenario ,
9
+ VideoCaptureOptions ,
10
+ VideoCodec ,
11
+ } from '../src/index' ;
3
12
import {
4
13
ConnectionQuality ,
5
14
ConnectionState ,
@@ -15,23 +24,17 @@ import {
15
24
RemoteTrackPublication ,
16
25
RemoteVideoTrack ,
17
26
Room ,
18
- RoomConnectOptions ,
19
27
RoomEvent ,
20
- RoomOptions ,
21
28
ScreenSharePresets ,
22
29
Track ,
23
30
TrackPublication ,
24
- VideoCaptureOptions ,
25
- VideoCodec ,
26
31
VideoPresets ,
27
32
VideoQuality ,
28
33
createAudioAnalyser ,
29
34
setLogLevel ,
30
35
supportsAV1 ,
31
36
supportsVP9 ,
32
37
} from '../src/index' ;
33
- import { ScalabilityMode } from '../src/room/track/options' ;
34
- import type { ChatMessage , SimulationScenario } from '../src/room/types' ;
35
38
import { isSVCCodec } from '../src/room/utils' ;
36
39
37
40
const $ = < T extends HTMLElement > ( id : string ) => document . getElementById ( id ) as T ;
Original file line number Diff line number Diff line change @@ -294,7 +294,7 @@ export enum RoomEvent {
294
294
MediaDevicesError = 'mediaDevicesError' ,
295
295
296
296
/**
297
- * A participant's permission has changed. Currently only fired on LocalParticipant.
297
+ * A participant's permission has changed.
298
298
* args: (prevPermissions: [[ParticipantPermission]], participant: [[Participant]])
299
299
*/
300
300
ParticipantPermissionsChanged = 'participantPermissionsChanged' ,
@@ -502,7 +502,7 @@ export enum ParticipantEvent {
502
502
AudioStreamAcquired = 'audioStreamAcquired' ,
503
503
504
504
/**
505
- * A participant's permission has changed. Currently only fired on LocalParticipant.
505
+ * A participant's permission has changed.
506
506
* args: (prevPermissions: [[ParticipantPermission]])
507
507
*/
508
508
ParticipantPermissionsChanged = 'participantPermissionsChanged' ,
Original file line number Diff line number Diff line change @@ -279,7 +279,8 @@ export default class Participant extends (EventEmitter as new () => TypedEmitter
279
279
permissions . canPublishSources . length !== this . permissions . canPublishSources . length ||
280
280
permissions . canPublishSources . some (
281
281
( value , index ) => value !== this . permissions ?. canPublishSources [ index ] ,
282
- ) ;
282
+ ) ||
283
+ permissions . canSubscribeMetrics !== this . permissions ?. canSubscribeMetrics ;
283
284
this . permissions = permissions ;
284
285
285
286
if ( changed ) {
You can’t perform that action at this time.
0 commit comments