Toggle navigation
Toggle navigation
This project
Loading...
Sign in
open-source
/
warply_sdk_framework
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
Manos Chorianopoulos
2023-01-23 14:01:15 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
65db53c42c23b10b531db566f94dc9cd899b8d10
65db53c4
1 parent
43ce916b
rollback session expiration
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
696 additions
and
696 deletions
SwiftWarplyFramework/Pods/Pods.xcodeproj/xcuserdata/manos.xcuserdatad/xcschemes/xcschememanagement.plist
SwiftWarplyFramework/SwiftWarplyFramework.xcodeproj/xcuserdata/manos.xcuserdatad/xcschemes/xcschememanagement.plist
SwiftWarplyFramework/SwiftWarplyFramework.xcworkspace/xcuserdata/manos.xcuserdatad/UserInterfaceState.xcuserstate
SwiftWarplyFramework/SwiftWarplyFramework/Warply/Warply.m
SwiftWarplyFramework/SwiftWarplyFramework/swiftApi.swift
SwiftWarplyFramework/Pods/Pods.xcodeproj/xcuserdata/manos.xcuserdatad/xcschemes/xcschememanagement.plist
View file @
65db53c
...
...
@@ -7,7 +7,7 @@
<key>
Pods-SwiftWarplyFramework.xcscheme_^#shared#^_
</key>
<dict>
<key>
orderHint
</key>
<integer>
1
</integer>
<integer>
0
</integer>
</dict>
</dict>
</dict>
...
...
SwiftWarplyFramework/SwiftWarplyFramework.xcodeproj/xcuserdata/manos.xcuserdatad/xcschemes/xcschememanagement.plist
View file @
65db53c
...
...
@@ -7,7 +7,7 @@
<key>
SwiftWarplyFramework.xcscheme_^#shared#^_
</key>
<dict>
<key>
orderHint
</key>
<integer>
0
</integer>
<integer>
1
</integer>
</dict>
</dict>
</dict>
...
...
SwiftWarplyFramework/SwiftWarplyFramework.xcworkspace/xcuserdata/manos.xcuserdatad/UserInterfaceState.xcuserstate
View file @
65db53c
No preview for this file type
SwiftWarplyFramework/SwiftWarplyFramework/Warply/Warply.m
View file @
65db53c
...
...
@@ -676,32 +676,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get Campaigns Personalized %@"
,
error
);
failure
(
error
);
...
...
@@ -1738,30 +1738,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at change password %@"
,
error
);
failure
(
error
);
...
...
@@ -1804,33 +1804,33 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
// NSError *errorToken = [NSError errorWithDomain:WARP_ERROR_DOMAIN code:401 userInfo:@{NSLocalizedDescriptionKey: NSLocalizedString(@"Empty response", @"Warply")}];
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
if
(
failure
)
{
failure
(
errorToken
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// failure(errorToken);
// }
// NSLog(@"Error at token %@", error );
// }];
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
error
);
}
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get profile %@"
,
error
);
failure
(
error
);
...
...
@@ -1876,32 +1876,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at post Event %@"
,
error
);
failure
(
error
);
...
...
@@ -1992,32 +1992,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at edit profile %@"
,
error
);
failure
(
error
);
...
...
@@ -2043,32 +2043,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get pacing details %@"
,
error
);
failure
(
error
);
...
...
@@ -2094,32 +2094,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at set pacing details %@"
,
error
);
failure
(
error
);
...
...
@@ -2182,32 +2182,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at consumer Integration %@"
,
error
);
failure
(
error
);
...
...
@@ -2231,30 +2231,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at change profile image %@"
,
error
);
failure
(
error
);
...
...
@@ -2278,30 +2278,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at add card %@"
,
error
);
failure
(
error
);
...
...
@@ -2325,30 +2325,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get cards %@"
,
error
);
failure
(
error
);
...
...
@@ -2372,30 +2372,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get delete card %@"
,
error
);
failure
(
error
);
...
...
@@ -2523,32 +2523,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get coupons %@"
,
error
);
failure
(
error
);
...
...
@@ -2572,30 +2572,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get transaction history %@"
,
error
);
failure
(
error
);
...
...
@@ -2619,30 +2619,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get points history %@"
,
error
);
failure
(
error
);
...
...
@@ -2668,32 +2668,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get Sharing History %@"
,
error
);
failure
(
error
);
...
...
@@ -2717,30 +2717,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at add address %@"
,
error
);
failure
(
error
);
...
...
@@ -2764,30 +2764,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get address %@"
,
error
);
failure
(
error
);
...
...
@@ -2856,30 +2856,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at edit address %@"
,
error
);
failure
(
error
);
...
...
@@ -2903,30 +2903,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at delete address %@"
,
error
);
failure
(
error
);
...
...
@@ -2950,30 +2950,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at redeem coupons %@"
,
error
);
failure
(
error
);
...
...
@@ -3218,32 +3218,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at redeem coupon sets %@"
,
error
);
failure
(
error
);
...
...
@@ -3288,32 +3288,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at redeem coupon sets %@"
,
error
);
failure
(
error
);
...
...
@@ -3339,32 +3339,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at cosmote Coupon Sharing %@"
,
error
);
failure
(
error
);
...
...
@@ -3390,32 +3390,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get cosmote sharing %@"
,
error
);
failure
(
error
);
...
...
@@ -3441,32 +3441,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at cosmote retrieve sharing %@"
,
error
);
failure
(
error
);
...
...
@@ -3511,32 +3511,32 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
NSLog
(
@"**************** WARPLY Response *****************"
);
NSLog
(
@"%@"
,
contextResponse
);
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// NSLog(@"**************** WARPLY Response *****************" );
// NSLog(@"%@", contextResponse );
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at submit Order %@"
,
error
);
failure
(
error
);
...
...
@@ -3560,30 +3560,30 @@ WL_VERSION_IMPLEMENTATION(WL_VERSION)
NSString
*
errorCode
=
[
dict
objectForKey
:
@"NSLocalizedDescription"
];
if
([
errorCode
isEqual
:
@"Request failed: unauthorized (401)"
])
{
NSString
*
errorDomain
=
[
error
domain
];
NSError
*
errorToken
=
[
NSError
errorWithDomain
:
errorDomain
code
:
401
userInfo
:
dict
];
// NSString* errorDomain = [error domain];
// NSError *errorToken = [NSError errorWithDomain:errorDomain code:401 userInfo:dict];
//
// if (failure) {
// failure(errorToken);
// }
[
self
refreshToken
:
^
(
NSDictionary
*
response
)
{
[
self
sendContext8
:
jsonData
successBlock
:
^
(
NSDictionary
*
contextResponse
)
{
if
(
success
)
{
success
(
contextResponse
);
}
}
failureBlock
:^
(
NSError
*
error
)
{
if
(
failure
)
{
failure
(
errorToken
);
failure
(
error
);
}
// [self refreshToken:^(NSDictionary *response) {
// [self sendContext8:jsonData successBlock:^(NSDictionary *contextResponse) {
// if (success) {
// success(contextResponse);
// }
// } failureBlock:^(NSError *error) {
// if (failure) {
// failure(error);
// }
// }];
// } failureBlock:^(NSError *error) {
// if (failure) {
// // [_db executeUpdate:@"DROP TABLE requestVariables"];
// failure(error);
// }
// NSLog(@"Error at token %@", error );
// }];
}];
}
failureBlock
:
^
(
NSError
*
error
)
{
if
(
failure
)
{
// [_db executeUpdate:@"DROP TABLE requestVariables"];
failure
(
error
);
}
NSLog
(
@"Error at token %@"
,
error
);
}];
}
else
{
NSLog
(
@"Error at get coupon sets %@"
,
error
);
failure
(
error
);
...
...
SwiftWarplyFramework/SwiftWarplyFramework/swiftApi.swift
View file @
65db53c
...
...
@@ -732,11 +732,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -1400,11 +1400,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -2442,11 +2442,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -4061,11 +4061,11 @@ public class swiftApi {
print
(
"===================="
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -4099,11 +4099,11 @@ public class swiftApi {
print
(
"===================="
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -4138,11 +4138,11 @@ public class swiftApi {
print
(
"===================="
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -4782,11 +4782,11 @@ public class swiftApi {
print
(
"getPacingDetails error: "
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -4851,11 +4851,11 @@ public class swiftApi {
print
(
"setPacingDetails error: "
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -4975,11 +4975,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -5044,11 +5044,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -5157,11 +5157,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -5229,11 +5229,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -5301,11 +5301,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -5558,11 +5558,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
@@ -6553,11 +6553,11 @@ public class swiftApi {
SwiftEventBus
.
post
(
"dynatrace"
,
sender
:
dynatraceEvent
)
if
let
error
=
error
as?
NSError
{
if
(
error
.
code
==
401
)
{
let
sessionEvent
=
swiftApi
.
LoyaltySDKSessionExpiredEventModel
()
sessionEvent
.
_sessionExpired
=
true
SwiftEventBus
.
post
(
"sdk_session_expired"
,
sender
:
sessionEvent
)
}
//
if (error.code == 401) {
//
let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
//
sessionEvent._sessionExpired = true
//
SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
//
}
failureCallback
(
error
.
code
)
}
else
{
...
...
Please
register
or
login
to post a comment