Mobile ads on Android too
This commit is contained in:
parent
801d24ae10
commit
784711c4e3
1 changed files with 6 additions and 5 deletions
|
@ -10,9 +10,9 @@ import classnames from 'classnames';
|
||||||
const ADS_URL =
|
const ADS_URL =
|
||||||
'https://cdn.vidcrunch.com/integrations/618bb4d28aac298191eec411/Lbry_Odysee.com_Responsive_Floating_DFP_Rev70_1011.js';
|
'https://cdn.vidcrunch.com/integrations/618bb4d28aac298191eec411/Lbry_Odysee.com_Responsive_Floating_DFP_Rev70_1011.js';
|
||||||
const ADS_TAG = 'vidcrunchJS537102317';
|
const ADS_TAG = 'vidcrunchJS537102317';
|
||||||
const IOS_ADS_URL =
|
const MOBILE_ADS_URL =
|
||||||
'https://cdn.vidcrunch.com/integrations/618bb4d28aac298191eec411/Lbry_Odysee.com_Mobile_Floating_DFP_Rev70_1611.js';
|
'https://cdn.vidcrunch.com/integrations/618bb4d28aac298191eec411/Lbry_Odysee.com_Mobile_Floating_DFP_Rev70_1611.js';
|
||||||
const IOS_ADS_TAG = 'vidcrunchJS199212779';
|
const MOBILE_ADS_TAG = 'vidcrunchJS199212779';
|
||||||
const EU_AD_URL =
|
const EU_AD_URL =
|
||||||
'https://tg1.vidcrunch.com/api/adserver/spt?AV_TAGID=61dff05c599f1e20b01085d4&AV_PUBLISHERID=6182c8993c8ae776bd5635e9';
|
'https://tg1.vidcrunch.com/api/adserver/spt?AV_TAGID=61dff05c599f1e20b01085d4&AV_PUBLISHERID=6182c8993c8ae776bd5635e9';
|
||||||
const EU_AD_TAG = 'AV61dff05c599f1e20b01085d4';
|
const EU_AD_TAG = 'AV61dff05c599f1e20b01085d4';
|
||||||
|
@ -54,6 +54,7 @@ function Ads(props: Props) {
|
||||||
} = props;
|
} = props;
|
||||||
|
|
||||||
const shouldShowAds = SHOW_ADS && !authenticated;
|
const shouldShowAds = SHOW_ADS && !authenticated;
|
||||||
|
const mobileAds = IS_ANDROID || IS_IOS;
|
||||||
|
|
||||||
// this is populated from app based on location
|
// this is populated from app based on location
|
||||||
let isInEu = localStorage.getItem('gdprRequired');
|
let isInEu = localStorage.getItem('gdprRequired');
|
||||||
|
@ -66,9 +67,9 @@ function Ads(props: Props) {
|
||||||
if (isInEu) {
|
if (isInEu) {
|
||||||
tagNameToUse = EU_AD_TAG;
|
tagNameToUse = EU_AD_TAG;
|
||||||
scriptUrlToUse = EU_AD_URL;
|
scriptUrlToUse = EU_AD_URL;
|
||||||
} else if (IS_IOS) {
|
} else if (mobileAds) {
|
||||||
tagNameToUse = IOS_ADS_TAG;
|
tagNameToUse = MOBILE_ADS_TAG;
|
||||||
scriptUrlToUse = IOS_ADS_URL;
|
scriptUrlToUse = MOBILE_ADS_URL;
|
||||||
} else {
|
} else {
|
||||||
tagNameToUse = ADS_TAG;
|
tagNameToUse = ADS_TAG;
|
||||||
scriptUrlToUse = ADS_URL;
|
scriptUrlToUse = ADS_URL;
|
||||||
|
|
Loading…
Reference in a new issue