openvidu-browser: fix targetElement types on constructors

pull/743/head
pabloFuente 2022-07-15 10:41:12 +02:00
parent 215f2828dd
commit 370a426fa9
2 changed files with 2 additions and 2 deletions

View File

@ -81,7 +81,7 @@ export class Publisher extends StreamManager {
/**
* @hidden
*/
constructor(targEl: string | HTMLElement, properties: PublisherProperties, openvidu: OpenVidu) {
constructor(targEl: string | HTMLElement | undefined, properties: PublisherProperties, openvidu: OpenVidu) {
super(new Stream((!!openvidu.session) ? openvidu.session : new Session(openvidu), { publisherProperties: properties, mediaConstraints: {} }), targEl);
platform = PlatformUtils.getInstance();
this.properties = properties;

View File

@ -40,7 +40,7 @@ export class Subscriber extends StreamManager {
/**
* @hidden
*/
constructor(stream: Stream, targEl: string | HTMLElement, properties: SubscriberProperties) {
constructor(stream: Stream, targEl: string | HTMLElement | undefined, properties: SubscriberProperties) {
super(stream, targEl);
this.element = this.targetElement;
this.stream = stream;