Authored by 刘金林

optimise 1.0.1

@@ -9,7 +9,7 @@ @@ -9,7 +9,7 @@
9 Pod::Spec.new do |s| 9 Pod::Spec.new do |s|
10 10
11 s.name = "YHEventReport" 11 s.name = "YHEventReport"
12 - s.version = "1.0.0" 12 + s.version = "1.0.1"
13 s.summary = "YHEventReport." 13 s.summary = "YHEventReport."
14 s.description = "无埋点SDK" 14 s.description = "无埋点SDK"
15 s.homepage = "http://git.yoho.cn/mobile/YH_EventReport" 15 s.homepage = "http://git.yoho.cn/mobile/YH_EventReport"
@@ -251,7 +251,7 @@ static NSString *const kParamKeyType = @"type"; @@ -251,7 +251,7 @@ static NSString *const kParamKeyType = @"type";
251 { 251 {
252 dispatch_async(self.queue, ^{ 252 dispatch_async(self.queue, ^{
253 if (self.mode == YHEventReportStrategyInterval) { 253 if (self.mode == YHEventReportStrategyInterval) {
254 - //todo save to disk 254 + [self saveToDiskOfInfo:self.infoCacheArray];
255 [self.infoCacheArray removeAllObjects]; 255 [self.infoCacheArray removeAllObjects];
256 } 256 }
257 }); 257 });
@@ -339,9 +339,6 @@ static NSString *const kParamKeyType = @"type"; @@ -339,9 +339,6 @@ static NSString *const kParamKeyType = @"type";
339 } 339 }
340 340
341 - (void)timerAction { 341 - (void)timerAction {
342 - if (!self.infoCacheArray.count) {  
343 - return;  
344 - }  
345 [self uploadEventAndCustomInfo:self.infoCacheArray type:YHEventReportTrackDataTypeHeartbeat completion:^(BOOL isSuccess) { 342 [self uploadEventAndCustomInfo:self.infoCacheArray type:YHEventReportTrackDataTypeHeartbeat completion:^(BOOL isSuccess) {
346 if (isSuccess) { 343 if (isSuccess) {
347 dispatch_async(self.queue, ^{ 344 dispatch_async(self.queue, ^{