diff --git a/src/kava.js b/src/kava.js index 8f943963..3dcd0ea7 100644 --- a/src/kava.js +++ b/src/kava.js @@ -9,7 +9,6 @@ import {ErrorPosition, KavaModel, SoundMode, TabMode, ScreenMode} from './kava-m const {Error: PKError, FakeEvent, Utils} = core; const DIVIDER: number = 1024; const TEXT_TYPE: string = 'TEXT'; - /** * Kaltura Advanced Analytics plugin. * @class Kava @@ -49,7 +48,7 @@ class Kava extends BasePlugin { * @memberof Kava */ static defaultConfig: Object = { - serviceUrl: '//analytics.kaltura.com/api_v3/index.php', + serviceUrl: `${Utils.Http.protocol}//analytics.kaltura.com/api_v3/index.php`, viewEventCountdown: 10, resetSessionCountdown: 30, dvrThreshold: 120, @@ -207,7 +206,7 @@ class Kava extends BasePlugin { */ sendAnalytics(model: Object): Promise<*> { return new Promise((resolve, reject) => { - OVPAnalyticsService.trackEvent(Utils.Http.protocol + this.config.serviceUrl, model) + OVPAnalyticsService.trackEvent(this.config.serviceUrl, model) .doHttpRequest() .then( response => {