Skip to content

Commit

Permalink
added method langauge() to capture language property
Browse files Browse the repository at this point in the history
  • Loading branch information
sheetalVBijale committed Sep 18, 2024
1 parent 426cee6 commit 6cffbc6
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/tracker.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import BrightcoveImaAdsTracker from './ads/brightcove-ima'
import FreewheelAdsTracker from './ads/freewheel'

export default class VideojsTracker extends nrvideo.VideoTracker {

getTech () {
let tech = this.player.tech({ IWillNotUseThisInPlugins: true })
if (tech) {
Expand Down Expand Up @@ -59,11 +58,11 @@ export default class VideojsTracker extends nrvideo.VideoTracker {
return this.player.mediainfo.name // Brightcove
}
}

getLanguage() {
return this.player && this.player.language_ ? this.player.language_ : null;
return this.player?.language()
}

getSrc () {
let tech = this.getTech()
if (tech && tech.getSrc) {
Expand Down

0 comments on commit 6cffbc6

Please sign in to comment.