Closed Goharhovhannisyan closed 7 years ago
Why did you open another pull request? This code change doesn't even compile..
I opened https://github.com/orta/ARAnalytics/pull/288 which contains the wanted changes from this pull request.
1 Error | |
---|---|
:no_entry_sign: | Please include a CHANGELOG entry. You can find it at CHANGELOG.md. |
Generated by :no_entry_sign: danger
(void)logTimingEvent:(NSString )event withInterval:(NSNumber )interval properties:(NSDictionary )properties { // Prepare properties dictionary if (!properties) { properties = @{@"value": @([interval intValue])}; } else { NSString category = properties.category; NSMutableDictionary *newProperties = [properties mutableCopy]; newProperties[@"value"] = @([interval intValue]); properties = newProperties; } if (!category) { category = @"default"; // category is a required value } // Send event [self event:event withProperties:properties];
// By Google's header, the interval should be seconds in milliseconds. GAIDictionaryBuilder _builder = [GAIDictionaryBuilder createTimingWithCategory:category interval:@((int)([interval doubleValue]_1000)) name:event label:nil]; [self send:[self finalizedPropertyDictionaryFromBuilder:builder withProperties:properties]]; }