Some CanGc fixes in components/script/dom (#33895)

Signed-off-by: taniishkaaa <tanishkasingh2004@gmail.com>
This commit is contained in:
tanishka 2024-10-18 17:22:37 +05:30 committed by GitHub
parent e33bae6d0a
commit 6b87ecc291
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 23 additions and 15 deletions

View file

@ -290,7 +290,14 @@ impl RTCPeerConnection {
return;
}
let track = MediaStreamTrack::new(&self.global(), id, ty);
let event = RTCTrackEvent::new(&self.global(), atom!("track"), false, false, &track);
let event = RTCTrackEvent::new(
&self.global(),
atom!("track"),
false,
false,
&track,
CanGc::note(),
);
event.upcast::<Event>().fire(self.upcast());
}