Skip to content

Commit

Permalink
[SDK-2449] Bumped SDK versions and updated logging code (#33)
Browse files Browse the repository at this point in the history
* Bumped version and updated logging code

* Changed to 4.0.0
  • Loading branch information
nsingh-branch authored Jun 11, 2024
1 parent dac62da commit fc3eb6f
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 14 deletions.
12 changes: 6 additions & 6 deletions AdobeBranchExtension.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "AdobeBranchExtension"
s.version = "3.1.0"
s.version = "4.0.0"
s.summary = "The Branch extension for Adobe Cloud Platform on iOS."

s.description = <<-DESC
Expand All @@ -22,9 +22,9 @@ Pod::Spec.new do |s|

s.source_files = 'AdobeBranchExtension/Classes/**/*'

s.dependency 'AEPCore', '~> 4.2.0'
s.dependency 'AEPLifecycle', '~> 4.2.0'
s.dependency 'AEPIdentity', '~> 4.2.0'
s.dependency 'AEPSignal', '~> 4.2.0'
s.dependency 'BranchSDK', '~> 3.2.0'
s.dependency 'AEPCore', '~> 5.1.0'
s.dependency 'AEPLifecycle', '~> 5.1.0'
s.dependency 'AEPIdentity', '~> 5.1.0'
s.dependency 'AEPSignal', '~> 5.1.0'
s.dependency 'BranchSDK', '~> 3.4.4'
end
12 changes: 6 additions & 6 deletions AdobeBranchExtension/Classes/AdobeBranchExtensionClass.m
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ - (nullable instancetype)initWithRuntime:(id<AEPExtensionRuntime> _Nonnull)runti
}

- (void)onRegistered {
[[BranchLogger shared] logDebug:@"AdobeBranchExtension listener registered"];
[[BranchLogger shared] logDebug:@"AdobeBranchExtension listener registered" error:nil];

[self deviceDataSharedState: NULL];

Expand Down Expand Up @@ -138,7 +138,7 @@ + (BOOL)configureEventExclusionList:(nullable NSArray<NSString *> *)eventNames e
// If already configured allowList
if ([AdobeBranchExtensionConfig instance].allowList.count != 0) {
*configError = [NSError errorWithDomain:AdobeBranchExtensionErrorDomain code:ABEBranchConflictConfiguration userInfo:@{NSLocalizedFailureReasonErrorKey: @"Already configured allowList for AdobeBranchExtensionConfig"}];
[[BranchLogger shared] logWarning:[NSString stringWithFormat:@"AdobeBranchExtensionConfig error: %@.", *configError]];
[[BranchLogger shared] logWarning:[NSString stringWithFormat:@"AdobeBranchExtensionConfig error: %@.", *configError] error:*configError];
return NO;
} else {
[AdobeBranchExtensionConfig instance].exclusionList = eventNames;
Expand All @@ -152,7 +152,7 @@ + (BOOL)configureEventAllowList:(nullable NSArray<NSString *> *)eventNames error
// If already configured allowList
if ([AdobeBranchExtensionConfig instance].exclusionList.count != 0) {
*configError = [NSError errorWithDomain:AdobeBranchExtensionErrorDomain code:ABEBranchConflictConfiguration userInfo:@{NSLocalizedFailureReasonErrorKey: @"Already configured exclusionList for AdobeBranchExtensionConfig"}];
[[BranchLogger shared] logWarning:[NSString stringWithFormat:@"AdobeBranchExtensionConfig error: %@.", *configError]];
[[BranchLogger shared] logWarning:[NSString stringWithFormat:@"AdobeBranchExtensionConfig error: %@.", *configError] error:*configError];
return NO;
} else {
[AdobeBranchExtensionConfig instance].allowList = eventNames;
Expand All @@ -164,7 +164,7 @@ + (BOOL)configureEventAllowList:(nullable NSArray<NSString *> *)eventNames error
#pragma mark - Action Events

- (void)handleEvent:(AEPEvent*)event {
[[BranchLogger shared] logDebug:[NSString stringWithFormat:@"Handling Event: %@", event]];
[[BranchLogger shared] logDebug:[NSString stringWithFormat:@"Handling Event: %@", event] error:nil];

if ([[AdobeBranchExtensionConfig instance].eventTypes containsObject:event.type] &&
[[AdobeBranchExtensionConfig instance].eventSources containsObject:event.source]) {
Expand Down Expand Up @@ -333,11 +333,11 @@ - (void) passAdobeIdsToBranch:(AEPEvent*)eventToProcess {
AEPSharedStateResult *configSharedState = [self.runtime getSharedStateWithExtensionName:eventToProcess.data[ABEAdobeEventDataKey_StateOwner] event:eventToProcess barrier:NO];

if (!configSharedState.value) {
[[BranchLogger shared] logWarning: @"BranchSDK_ Could not process event, configuration shared state is pending"];
[[BranchLogger shared] logWarning: @"BranchSDK_ Could not process event, configuration shared state is pending" error:nil];
return;
}
if (error) {
[[BranchLogger shared] logWarning: @"BranchSDK_ Could not process event, an error occured while retrieving configuration shared state"];
[[BranchLogger shared] logWarning: @"BranchSDK_ Could not process event, an error occured while retrieving configuration shared state" error:nil];
return;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
objectVersion = 51;
objectVersion = 54;
objects = {

/* Begin PBXBuildFile section */
Expand All @@ -25,6 +25,7 @@
ACAE81332122645B0049505B /* UserNotifications.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = ACAE81322122645B0049505B /* UserNotifications.framework */; };
ACAE8135212264610049505B /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = ACAE8134212264610049505B /* SystemConfiguration.framework */; };
C10F392A278E39AD00BF5D36 /* AdSupport.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C10F3929278E39AD00BF5D36 /* AdSupport.framework */; };
C12534432C18F6E4008A83C4 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = C12534422C18EE39008A83C4 /* PrivacyInfo.xcprivacy */; };
/* End PBXBuildFile section */

/* Begin PBXFileReference section */
Expand Down Expand Up @@ -63,6 +64,7 @@
ACF671D921534E4F00CDC900 /* ACPLifecycle_iOS.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ACPLifecycle_iOS.framework; path = Pods/ACPCoreBeta/ACPLifecycle_iOS.framework; sourceTree = "<group>"; };
B0EA9C30991048D8A522C726 /* Pods_AdobeBranchExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AdobeBranchExample.framework; sourceTree = BUILT_PRODUCTS_DIR; };
C10F3929278E39AD00BF5D36 /* AdSupport.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AdSupport.framework; path = System/Library/Frameworks/AdSupport.framework; sourceTree = SDKROOT; };
C12534422C18EE39008A83C4 /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = PrivacyInfo.xcprivacy; sourceTree = "<group>"; };
F8688AE753553EE80251EE11 /* Pods-adobe-branch-example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-adobe-branch-example.release.xcconfig"; path = "Pods/Target Support Files/Pods-adobe-branch-example/Pods-adobe-branch-example.release.xcconfig"; sourceTree = "<group>"; };
FD81B1B19DDC0E314016948F /* Pods-adobe-branch-example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-adobe-branch-example.debug.xcconfig"; path = "Pods/Target Support Files/Pods-adobe-branch-example/Pods-adobe-branch-example.debug.xcconfig"; sourceTree = "<group>"; };
/* End PBXFileReference section */
Expand Down Expand Up @@ -118,6 +120,7 @@
ACAE8106212263F30049505B /* AdobeBranchExample */ = {
isa = PBXGroup;
children = (
C12534422C18EE39008A83C4 /* PrivacyInfo.xcprivacy */,
ACF671CD2150B42800CDC900 /* AdobeBranchExample.entitlements */,
ACAE8107212263F30049505B /* AppDelegate.h */,
ACAE8108212263F30049505B /* AppDelegate.m */,
Expand Down Expand Up @@ -229,6 +232,7 @@
ACAE8111212263F40049505B /* Assets.xcassets in Resources */,
4DE097FD219CEABE008AC401 /* Products.json in Resources */,
4D16DBA421AF037F00E362A2 /* Launch Screen.storyboard in Resources */,
C12534432C18F6E4008A83C4 /* PrivacyInfo.xcprivacy in Resources */,
ACAE810F212263F40049505B /* Main.storyboard in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
// initialize Branch session, [AdobeBranchExtension initSessionWithLaunchOptions] is different from
// [[Branch getInstance] initSessionWithLaunchOptions] in that it holds up initialization in order to collect
// Adobe IDs and pass them to Branch as request metadata, see [AdobeBranchExtension delayInitSessionToCollectAdobeIDs]
[[Branch getInstance] enableLogging];
[Branch enableLogging];
[AdobeBranchExtension initSessionWithLaunchOptions:launchOptions andRegisterDeepLinkHandler:^(NSDictionary * _Nullable params, NSError * _Nullable error) {
if (!error && params && [params[@"+clicked_branch_link"] boolValue]) {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath
[linkProperties addControlParam:@"$desktop_url" withValue: @"https://branch.io/branch/Glasses.html"];

[branchUniversalObject getShortUrlWithLinkProperties:linkProperties andCallback:^(NSString *url, NSError *error) {
NSLog(@"Created Short Link: %@", url);
[self showCreatedLink:url];
}];
break;
Expand Down

0 comments on commit fc3eb6f

Please sign in to comment.