Check if video el still exists before exoplayer resize in ha-hls-player (#7317)

Co-authored-by: Bram Kragten <mail@bramkragten.nl>
This commit is contained in:
uvjustin 2020-10-13 18:15:30 +08:00 committed by GitHub
parent ddcf89e6a2
commit 0df9080bbb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -154,6 +154,9 @@ class HaHLSPlayer extends LitElement {
}
private _resizeExoPlayer = () => {
if (!this._videoEl) {
return;
}
const rect = this._videoEl.getBoundingClientRect();
this.hass!.auth.external!.fireMessage({
type: "exoplayer/resize",