From 951ef8294e9eae8f0b42292059daf0c972dbc48f Mon Sep 17 00:00:00 2001 From: BO41 Date: Wed, 24 Oct 2018 21:50:18 +0200 Subject: add noImplicitThis flag (#1324) --- client/src/assets/player/peertube-player.ts | 4 ++-- client/src/assets/player/settings-menu-button.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'client/src/assets') diff --git a/client/src/assets/player/peertube-player.ts b/client/src/assets/player/peertube-player.ts index db63071cb..aaa1170b6 100644 --- a/client/src/assets/player/peertube-player.ts +++ b/client/src/assets/player/peertube-player.ts @@ -213,7 +213,7 @@ function addContextMenu (player: any, videoEmbedUrl: string) { { label: player.localize('Copy the video URL at the current time'), listener: function () { - const player = this + const player = this as Player copyToClipboard(buildVideoLink(player.currentTime())) } }, @@ -226,7 +226,7 @@ function addContextMenu (player: any, videoEmbedUrl: string) { { label: player.localize('Copy magnet URI'), listener: function () { - const player = this + const player = this as Player copyToClipboard(player.peertube().getCurrentVideoFile().magnetUri) } } diff --git a/client/src/assets/player/settings-menu-button.ts b/client/src/assets/player/settings-menu-button.ts index aa7281727..a7aefdcc3 100644 --- a/client/src/assets/player/settings-menu-button.ts +++ b/client/src/assets/player/settings-menu-button.ts @@ -182,7 +182,7 @@ class SettingsButton extends Button { } addMenuItem (entry: any, options: any) { - const openSubMenu = function () { + const openSubMenu = function (this: any) { if (videojsUntyped.dom.hasClass(this.el_, 'open')) { videojsUntyped.dom.removeClass(this.el_, 'open') } else { -- cgit v1.2.3