Skip to content

Commit

Permalink
fix(ios): admob shows only non-personalized ads (#5262)
Browse files Browse the repository at this point in the history
* fix: conditional was always true if requestNonPersonalizedAdsOnly contained a value
  • Loading branch information
dylancom authored May 4, 2021
1 parent 0243048 commit 0b62d5a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/admob/ios/RNFBAdMob/RNFBAdMobCommon.m
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ + (GADRequest *)buildAdRequest:(NSDictionary *)adRequestOptions {
GADRequest *request = [GADRequest request];
NSMutableDictionary *extras = [@{} mutableCopy];

if (adRequestOptions[@"requestNonPersonalizedAdsOnly"]) {
if (adRequestOptions[@"requestNonPersonalizedAdsOnly"] && [adRequestOptions[@"requestNonPersonalizedAdsOnly"] boolValue]) {
extras[@"npa"] = @"1";
}

Expand Down

1 comment on commit 0b62d5a

@vercel
Copy link

@vercel vercel bot commented on 0b62d5a May 4, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.