Skip to content

Commit

Permalink
Release 0.0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
yaoyue committed Jul 24, 2021
1 parent cc9cad9 commit 6dac182
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 10 deletions.
2 changes: 1 addition & 1 deletion SensorsABTest/SABConstants.m
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#import "SABConstants.h"

// 当前版本号
NSString *const kSABLibVersion = @"0.0.4";
NSString *const kSABLibVersion = @"0.0.5";

// SA 最低支持版本
NSString *const kSABMinSupportedSALibVersion = @"2.1.14";
Expand Down
24 changes: 16 additions & 8 deletions SensorsABTest/SABridge/SABEventTracker.m
Original file line number Diff line number Diff line change
Expand Up @@ -44,16 +44,24 @@ - (void)sensorsabtest_trackEvent:(NSMutableDictionary *)event isSignUp:(BOOL)isS
tempEvent = [event mutableCopy];
}

// 用于移除 properties 中的 loginId, distinctId,anonymousId
NSMutableDictionary *tempProperties = [properties mutableCopy];

// 修改 loginId, distinctId,anonymousId
tempEvent[kSALoginId] = properties[kSABLoginId];
tempEvent[kSADistinctId] = properties[kSABDistinctId];
tempEvent[kSAAnonymousId] = properties[kSABAnonymousId];
if (properties[kSABLoginId]) {
tempEvent[kSALoginId] = properties[kSABLoginId];
tempProperties[kSABLoginId] = nil;
}

// properties 中 移除 loginId, distinctId,anonymousId
NSMutableDictionary *tempProperties = [properties mutableCopy];
tempProperties[kSABLoginId] = nil;
tempProperties[kSABDistinctId] = nil;
tempProperties[kSABAnonymousId] = nil;
if (properties[kSABDistinctId]) {
tempEvent[kSADistinctId] = properties[kSABDistinctId];
tempProperties[kSABDistinctId] = nil;
}

if (properties[kSABAnonymousId]) {
tempEvent[kSAAnonymousId] = properties[kSABAnonymousId];
tempProperties[kSABAnonymousId] = nil;
}

tempEvent[kSAProperties] = tempProperties;
[self sensorsabtest_trackEvent:tempEvent isSignUp:isSignUp];
Expand Down
2 changes: 1 addition & 1 deletion SensorsABTesting.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'SensorsABTesting'
s.version = "0.0.4"
s.version = "0.0.5"
s.summary = 'The official iOS SDK of Sensors A/B Testing.'
s.homepage = 'http://www.sensorsdata.cn'
s.license = { :type => 'Apache 2.0', :file => 'LICENSE' }
Expand Down

0 comments on commit 6dac182

Please sign in to comment.