Manos Chorianopoulos

test sendDeviceInfo

......@@ -994,10 +994,6 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSDictionary *postDictionary = @{@"consumer_data":@{@"action": @"handle_user_details", @"process": @"get"}};
NSData *jsonData = [NSJSONSerialization dataWithJSONObject:postDictionary options:0 error:NULL];
[self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// TODO: DELETE
NSLog(@"**************** getProfile Response *****************" );
NSLog(@"%@", contextResponse );
if (success) {
success(contextResponse);
}
......@@ -1005,10 +1001,6 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSLog(@"%@", contextResponse );
} failureBlock:^(NSError *error) {
// TODO: DELETE
NSLog(@"**************** getProfile error *****************" );
NSLog(@"%@", error );
if (failure) {
NSDictionary* dict = [NSDictionary alloc];
dict = [error userInfo];
......@@ -1023,10 +1015,6 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSLog(@"%@", contextResponse );
} failureBlock:^(NSError *error) {
// TODO: DELETE
NSLog(@"**************** getProfile error 2 *****************" );
NSLog(@"%@", error );
if (failure) {
failure(error);
}
......@@ -2856,9 +2844,6 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
failureBlock:(void (^)(NSError *error))failureBlock
{
// TODO: DELETE
NSLog(@"**************** getProfile sendContext8 *****************" );
BOOL appIsRegisteredWithWarply = [self isRegistrationValid];
if (WL_FEATURE_IS_DISABLED_WITH_KEY(WL_WARPLY_ENABLED))
......@@ -3388,9 +3373,6 @@ CGFloat DistanceBetweenTwoPoints(CGPoint point1,CGPoint point2)
failureBlock:(void (^)(NSError *error))failureBlock
{
// TODO: DELETE
NSLog(@"**************** getProfileRequestInvocationWithType *****************" );
void (^ successBlockCopy)(void) = [successBlock copy];
void (^ failureBlockCopy)(void) = [failureBlock copy];
......@@ -4174,10 +4156,6 @@ CGFloat DistanceBetweenTwoPoints(CGPoint point1,CGPoint point2)
WLLOG(@"*************************************************");
NSDictionary *contextResponse=JSON;
// TODO: DELETE
NSLog(@"**************** runGetProfileRequestWithType contextResponse *****************" );
NSLog(@"%@", contextResponse );
if ([JSON objectForKey:@"status"]) {
int status = [[JSON valueForKey:@"status"] intValue];
......@@ -4206,44 +4184,24 @@ CGFloat DistanceBetweenTwoPoints(CGPoint point1,CGPoint point2)
if (successBlock)
{
// TODO: DELETE
NSLog(@"**************** runGetProfileRequestWithType successBlock contextResponse *****************" );
NSLog(@"%@", contextResponse );
if ([path length]!=0)
{
// TODO: DELETE
NSLog(@"**************** runGetProfileRequestWithType successBlock [contextResponse valueForKey:path] *****************" );
NSLog(@"%@", [contextResponse valueForKey:path] );
successBlock([contextResponse valueForKey:path]);
return;
}
// TODO: DELETE
NSLog(@"**************** runGetProfileRequestWithType successBlock contextResponse 2 *****************" );
NSLog(@"%@", contextResponse );
successBlock(contextResponse);
}
}else{
// TODO: DELETE
NSLog(@"**************** runGetProfileRequestWithType else *****************" );
NSLog(@"%@", contextResponse );
NSError *error = [NSError errorWithDomain:WARP_ERROR_DOMAIN code:1026 userInfo:@{NSLocalizedDescriptionKey: NSLocalizedString(@"Empty response", @"Warply")}];
if (failureBlock)
failureBlock(error);
// TODO: DELETE
NSLog(@"**************** runGetProfileRequestWithType else error *****************" );
NSLog(@"%@", error );
}
}
......
......@@ -364,9 +364,16 @@ static const char* jailbreak_apps[] =
NSDictionary *oldApplicationData = [defaults objectForKey:WL_APPLICATION_DATA];
BOOL application_data_has_changed = ![[self applicationData] isEqualToDictionary:oldApplicationData];
if (device_info_has_changed || application_data_has_changed || _isMissingDeviceInfo) {
// TODO: DELETE
NSLog(@"oldDeviceInfo: %@",oldDeviceInfo);
NSLog(@"device_info_has_changed: %@",device_info_has_changed);
NSLog(@"oldApplicationData: %@",oldApplicationData);
NSLog(@"application_data_has_changed: %@",application_data_has_changed);
NSLog(@"_isMissingDeviceInfo: %@",_isMissingDeviceInfo);
// if (device_info_has_changed || application_data_has_changed || _isMissingDeviceInfo) {
[self sendDeviceInfo];
}
// }
}
///////////////////////////////////////////////////////////////////////////////
......