This commit is contained in:
jenkins 2023-06-12 17:09:03 -07:00
Родитель c0ddec1efe
Коммит 256fb333e1
3 изменённых файлов: 9 добавлений и 5 удалений

Просмотреть файл

@ -2,7 +2,7 @@ Pod::Spec.new do |s|
s.authors = 'AppLovin Corporation'
s.name = 'AppLovinMediationHyprMXAdapter'
s.version = '6.2.0.0'
s.version = '6.2.0.1'
s.platform = :ios, '9.0'
s.summary = 'HyprMX adapter used for mediation with the AppLovin MAX SDK'
s.homepage = "https://github.com/CocoaPods/Specs/search?o=desc&q=#{s.name}&s=indexed"

Просмотреть файл

@ -1,5 +1,9 @@
# Changelog
## 6.2.0.1
* Add support to set `ageRestrictedUser` on initialization.
* Remove the `ageRestrictedUser` check from user consent.
## 6.2.0.0
* Certified with HyprMX SDK 6.2.0.
* Updated podspec to use `HyprMX` instead of `HyprMX/Core`.

Просмотреть файл

@ -9,7 +9,7 @@
#import "ALHyprMXMediationAdapter.h"
#import <HyprMX/HyprMX.h>
#define ADAPTER_VERSION @"6.2.0.0"
#define ADAPTER_VERSION @"6.2.0.1"
/**
* Dedicated delegate object for HyprMX initialization.
@ -118,6 +118,7 @@ static NSString *const kHyprMXRandomUserIdKey = @"com.applovin.sdk.mediation.ran
[HyprMX initializeWithDistributorId: distributorId
userId: userId
consentStatus: [self consentStatusWithParameters: parameters]
ageRestrictedUser: parameters.ageRestrictedUser.boolValue
initializationDelegate: self.initializationDelegate];
}
else
@ -285,15 +286,14 @@ static NSString *const kHyprMXRandomUserIdKey = @"com.applovin.sdk.mediation.ran
- (HyprConsentStatus)consentStatusWithParameters:(id<MAAdapterParameters>)parameters
{
NSNumber *hasUserConsent = parameters.hasUserConsent;
NSNumber *isAgeRestrictedUser = parameters.isAgeRestrictedUser;
NSNumber *isDoNotSell = parameters.isDoNotSell;
// isTrue/isFalse/isNil to match the spec from HyprMX
if ( ( [self isNil: isDoNotSell] || [self isFalse: isDoNotSell] ) && [self isTrue: hasUserConsent] && [self isFalse: isAgeRestrictedUser] )
if ( ( [self isNil: isDoNotSell] || [self isFalse: isDoNotSell] ) && [self isTrue: hasUserConsent] )
{
return CONSENT_GIVEN;
}
else if ( [self isTrue: isDoNotSell] || [self isFalse: hasUserConsent] || [self isTrue: isAgeRestrictedUser] )
else if ( [self isTrue: isDoNotSell] || [self isFalse: hasUserConsent] )
{
return CONSENT_DECLINED;
}