From 583e1cf5d074fc2a83414a3fc05e89b519e278dc Mon Sep 17 00:00:00 2001 From: echo Date: Thu, 5 Oct 2023 11:37:37 -0700 Subject: [PATCH 1/2] Add public API to route requests to EU endpoints --- BranchSDK/Branch.h | 7 +++++++ BranchSDK/Branch.m | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/BranchSDK/Branch.h b/BranchSDK/Branch.h index 54bb55377..820376a8d 100644 --- a/BranchSDK/Branch.h +++ b/BranchSDK/Branch.h @@ -568,6 +568,13 @@ extern NSString * __nonnull const BNCSpotlightFeature; */ - (void)enableLogging; +/** + Send requests to EU endpoints. + + This feature must also be enabled on the server side, otherwise the server will drop requests. Contact your account manager for details. + */ +- (void)useEUEndpoints; + /** setDebug is deprecated and all functionality has been disabled. diff --git a/BranchSDK/Branch.m b/BranchSDK/Branch.m index 8a307809a..99f2908ff 100644 --- a/BranchSDK/Branch.m +++ b/BranchSDK/Branch.m @@ -419,6 +419,10 @@ - (void)enableLogging { BNCLogSetDisplayLevel(BNCLogLevelDebug); } +- (void)useEUEndpoints { + [[BNCServerAPI sharedInstance] useEUServers]; +} + - (void)setDebug { NSLog(@"Branch setDebug is deprecated and all functionality has been disabled. " "If you wish to enable logging, please invoke enableLogging. " From 7e612ff6d1ba26abbd61a341aa68d9ee57a9b99a Mon Sep 17 00:00:00 2001 From: echo Date: Thu, 5 Oct 2023 14:22:37 -0700 Subject: [PATCH 2/2] Fix the call, it's a property not a method --- BranchSDK/Branch.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/BranchSDK/Branch.m b/BranchSDK/Branch.m index 99f2908ff..24bcf7ef0 100644 --- a/BranchSDK/Branch.m +++ b/BranchSDK/Branch.m @@ -420,7 +420,7 @@ - (void)enableLogging { } - (void)useEUEndpoints { - [[BNCServerAPI sharedInstance] useEUServers]; + [BNCServerAPI sharedInstance].useEUServers = YES; } - (void)setDebug {