refactor(core): removed unnecessary class variable
This commit is contained in:
@@ -11,7 +11,6 @@ import { BaseUI } from '../ui';
|
|||||||
|
|
||||||
export class VP {
|
export class VP {
|
||||||
private video: HTMLVideoElement;
|
private video: HTMLVideoElement;
|
||||||
private videoSrc?: NodeListOf<HTMLSourceElement>;
|
|
||||||
private config?: PlayerConfig;
|
private config?: PlayerConfig;
|
||||||
private adapter: AdapterAPI;
|
private adapter: AdapterAPI;
|
||||||
private ui?: BaseUI;
|
private ui?: BaseUI;
|
||||||
@@ -22,9 +21,7 @@ export class VP {
|
|||||||
*/
|
*/
|
||||||
constructor(video: string | HTMLVideoElement, config: PlayerConfig) {
|
constructor(video: string | HTMLVideoElement, config: PlayerConfig) {
|
||||||
this.config = config;
|
this.config = config;
|
||||||
|
|
||||||
this.video = this.videoElement(video);
|
this.video = this.videoElement(video);
|
||||||
this.videoSrc = this.video?.querySelectorAll<HTMLSourceElement>('source');
|
|
||||||
|
|
||||||
if (!this.config.type) {
|
if (!this.config.type) {
|
||||||
throw new Error('Type not specified in config.');
|
throw new Error('Type not specified in config.');
|
||||||
|
|||||||
Reference in New Issue
Block a user