@@ -499,8 +499,8 @@ - (void)addInstrumentationToJSON:(NSMutableDictionary *)json {
499499// BNCReferringURLUtility requires the endpoint string to determine which query params are applied
500500- (void )addReferringURLsToJSON : (NSMutableDictionary *)json forEndpoint : (NSString *)endpoint {
501501 // Not a singleton, but BNCReferringURLUtility does pull from storage
502- if ([self .preferenceHelper attributionLevel ] == BranchAttributionLevelFull ||
503- [self .preferenceHelper attributionLevelInitialized ] == false ) {
502+ if ([[ self .preferenceHelper attributionLevel ] isEqualToString: BranchAttributionLevelFull] ||
503+ ! [self .preferenceHelper attributionLevelInitialized ]) {
504504 BNCReferringURLUtility *utility = [BNCReferringURLUtility new ];
505505 NSDictionary *urlQueryParams = [utility referringURLQueryParamsForEndpoint: endpoint];
506506 [json bnc_safeAddEntriesFromDictionary: urlQueryParams];
@@ -542,13 +542,13 @@ - (NSDictionary *)v2dictionary {
542542 } else {
543543 BranchAttributionLevel attributionLevel = [self .preferenceHelper attributionLevel ];
544544
545- if (attributionLevel == BranchAttributionLevelFull ||
546- [self .preferenceHelper attributionLevelInitialized ] == false ) {
545+ if ([ attributionLevel isEqualToString: BranchAttributionLevelFull] ||
546+ ! [self .preferenceHelper attributionLevelInitialized ]) {
547547 [dictionary bnc_safeSetObject: self .deviceInfo.advertiserId forKey: @" idfa" ];
548548 }
549-
550- if (attributionLevel != BranchAttributionLevelNone ||
551- [self .preferenceHelper attributionLevelInitialized ] == false ) {
549+
550+ if (![ attributionLevel isEqualToString: BranchAttributionLevelNone] ||
551+ ! [self .preferenceHelper attributionLevelInitialized ]) {
552552 [dictionary bnc_safeSetObject: self .deviceInfo.vendorId forKey: @" idfv" ];
553553 }
554554 }
@@ -610,14 +610,14 @@ - (void)updateDeviceInfoToMutableDictionary:(NSMutableDictionary *)dict {
610610 [self .deviceInfo checkAdvertisingIdentifier ];
611611
612612 // Only include hardware ID fields for Full Attribution Level
613- if ([ self .preferenceHelper attributionLevel ] == BranchAttributionLevelFull
613+ if (([[ self .preferenceHelper attributionLevel ] isEqualToString: BranchAttributionLevelFull])
614614 || [self .preferenceHelper attributionLevelInitialized ] == false ) {
615-
616- // hardware id information. idfa, idfv or random
617- NSString *hardwareId = [self .deviceInfo.hardwareId copy ];
618- NSString *hardwareIdType = [self .deviceInfo.hardwareIdType copy ];
619- NSNumber *isRealHardwareId = @(self.deviceInfo .isRealHardwareId );
620-
615+
616+ // hardware id information. idfa, idfv or random
617+ NSString *hardwareId = [self .deviceInfo.hardwareId copy ];
618+ NSString *hardwareIdType = [self .deviceInfo.hardwareIdType copy ];
619+ NSNumber *isRealHardwareId = @(self.deviceInfo .isRealHardwareId );
620+
621621 if (hardwareId != nil && hardwareIdType != nil && isRealHardwareId != nil ) {
622622 dict[BRANCH_REQUEST_KEY_HARDWARE_ID] = hardwareId;
623623 dict[BRANCH_REQUEST_KEY_HARDWARE_ID_TYPE] = hardwareIdType;
0 commit comments