livekit-client 2.5.5 → 2.5.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10995,7 +10995,7 @@ function getOSVersion(ua) {
10995
10995
  return ua.includes('mac os') ? getMatch(/\(.+?(\d+_\d+(:?_\d+)?)/, ua, 1).replace(/_/g, '.') : undefined;
10996
10996
  }
10997
10997
 
10998
- var version$1 = "2.5.5";
10998
+ var version$1 = "2.5.6";
10999
10999
 
11000
11000
  const version = version$1;
11001
11001
  const protocolVersion = 15;
@@ -12757,6 +12757,11 @@ class E2EEManager extends eventsExports.EventEmitter {
12757
12757
  }
12758
12758
  break;
12759
12759
  case 'enable':
12760
+ if (data.enabled) {
12761
+ this.keyProvider.getKeys().forEach(keyInfo => {
12762
+ this.postKey(keyInfo);
12763
+ });
12764
+ }
12760
12765
  if (this.encryptionEnabled !== data.enabled && data.participantIdentity === ((_a = this.room) === null || _a === void 0 ? void 0 : _a.localParticipant.identity)) {
12761
12766
  this.emit(EncryptionEvent.ParticipantEncryptionStatusChanged, data.enabled, this.room.localParticipant);
12762
12767
  this.encryptionEnabled = data.enabled;
@@ -12767,11 +12772,6 @@ class E2EEManager extends eventsExports.EventEmitter {
12767
12772
  }
12768
12773
  this.emit(EncryptionEvent.ParticipantEncryptionStatusChanged, data.enabled, participant);
12769
12774
  }
12770
- if (this.encryptionEnabled) {
12771
- this.keyProvider.getKeys().forEach(keyInfo => {
12772
- this.postKey(keyInfo);
12773
- });
12774
- }
12775
12775
  break;
12776
12776
  case 'ratchetKey':
12777
12777
  this.keyProvider.emit(KeyProviderEvent.KeyRatcheted, data.material, data.keyIndex);
@@ -12865,10 +12865,10 @@ class E2EEManager extends eventsExports.EventEmitter {
12865
12865
  if (!this.room) {
12866
12866
  throw new TypeError("expected room to be present on signal connect");
12867
12867
  }
12868
- this.setParticipantCryptorEnabled(this.room.localParticipant.isE2EEEnabled, this.room.localParticipant.identity);
12869
12868
  keyProvider.getKeys().forEach(keyInfo => {
12870
12869
  this.postKey(keyInfo);
12871
12870
  });
12871
+ this.setParticipantCryptorEnabled(this.room.localParticipant.isE2EEEnabled, this.room.localParticipant.identity);
12872
12872
  });
12873
12873
  room.localParticipant.on(ParticipantEvent.LocalTrackPublished, publication => __awaiter(this, void 0, void 0, function* () {
12874
12874
  this.setupE2EESender(publication.track, publication.track.sender);