Skip to content

Commit

Permalink
fix(FEC-9013): [iOS] - Player doesnt play ads native (#234)
Browse files Browse the repository at this point in the history
set default value in ima plugin (kaltura/playkit-js-ima#103) instead in kaltura player.
delayInitUntilSourceSelected will be set to true always by default.
  • Loading branch information
yairans authored Apr 3, 2019
1 parent b2e8a86 commit 60edaf6
Showing 1 changed file with 0 additions and 23 deletions.
23 changes: 0 additions & 23 deletions src/common/utils/setup-helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,6 @@ function getDefaultOptions(options: PartialKPOptionsObject): KPOptionsObject {
setDefaultAnalyticsPlugin(defaultOptions);
configureVrDefaultOptions(defaultOptions);
configureExternalStreamRedirect(defaultOptions);
configureDelayAdsInitialization(defaultOptions);
return defaultOptions;
}
Expand All @@ -278,28 +277,6 @@ function checkNativeHlsSupport(options: KPOptionsObject): void {
}
}

/**
* Configures the delayInitUntilSourceSelected property for the ads plugin based on the runtime platform and the playsinline config value.
* @private
* @param {KPOptionsObject} options - kaltura player options
* @returns {void}
*/
function configureDelayAdsInitialization(options: KPOptionsObject): void {
if (isIos() && options.plugins && options.plugins.ima) {
const playsinline = Utils.Object.getPropertyPath(options, 'playback.playsinline');
const delayInitUntilSourceSelected = Utils.Object.getPropertyPath(options, 'plugins.ima.delayInitUntilSourceSelected');
if ((typeof playsinline !== 'boolean' || playsinline === true) && typeof delayInitUntilSourceSelected !== 'boolean') {
Utils.Object.mergeDeep(options, {
plugins: {
ima: {
delayInitUntilSourceSelected: true
}
}
});
}
}
}

/**
* Sets config option for native text track support
* @private
Expand Down

0 comments on commit 60edaf6

Please sign in to comment.