Skip to content

Commit

Permalink
fix(UI): Console error on remote.cancelwatchavailability() method in …
Browse files Browse the repository at this point in the history
…remote playback feature
  • Loading branch information
avelad committed Oct 23, 2023
1 parent f81a16a commit 0707f27
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions ui/remote_button.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,13 @@ shaka.ui.RemoteButton = class extends shaka.ui.Element {
}

/** @override */
release() {
if (this.video.remote && this.callbackId_ != -1) {
this.video.remote.cancelWatchAvailability(this.callbackId_);
async release() {
try {
if (this.video.remote && this.callbackId_ != -1) {
await this.video.remote.cancelWatchAvailability(this.callbackId_);
}
} catch (error) {
// Ignore this error.
}

super.release();
Expand Down

0 comments on commit 0707f27

Please sign in to comment.