no message

This commit is contained in:
Giuseppe Nucifora 2016-03-17 10:38:52 +01:00
parent ce70ebf7fc
commit 22499a85d3
12 changed files with 180 additions and 164 deletions

View File

@ -139,9 +139,7 @@
NSLog(@"response : %@",responseObject);
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(5 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[responseObject reloadFormServer];
});
NSLog(@"%@",[User currentUser]);
} failure:^(NSError * _Nonnull error) {
NSLog(@"response : %@",error);
}];

View File

@ -26,11 +26,11 @@ PODS:
- Expecta+Snapshots (2.0.0):
- Expecta (~> 1.0)
- FBSnapshotTestCase/Core (~> 2.0.3)
- FBSDKCoreKit (4.10.0):
- FBSDKCoreKit (4.10.1):
- Bolts (~> 1.5)
- FBSDKLoginKit (4.10.0):
- FBSDKLoginKit (4.10.1):
- FBSDKCoreKit
- FBSDKShareKit (4.10.0):
- FBSDKShareKit (4.10.1):
- FBSDKCoreKit
- FBSnapshotTestCase (2.0.7):
- FBSnapshotTestCase/SwiftSupport (= 2.0.7)
@ -44,7 +44,7 @@ PODS:
- CocoaSecurity (~> 1.2.2)
- nv-ios-http-status (0.0.1)
- PEAR-FileManager-iOS (1.3.1)
- PNObject (0.4.5):
- PNObject (0.4.6):
- AFNetworking
- CodFis-Helper
- FBSDKCoreKit
@ -93,9 +93,9 @@ SPEC CHECKSUMS:
CodFis-Helper: 28be4c74d7202542459d72354f59b1215871de87
Expecta: e1c022fcd33910b6be89c291d2775b3fe27a89fe
Expecta+Snapshots: 29b38dd695bc72a0ed2bea833937d78df41943ba
FBSDKCoreKit: 13bec8373fb3af94d44daf2aa1e0958687897fbd
FBSDKLoginKit: d3d4a2e9d31954deb00bfea964167a05ca1ea976
FBSDKShareKit: 54587b4624706ace1e810cf83412a918141f807a
FBSDKCoreKit: d2aaed5e9ab7d8d6301c533376a1fbff1cf3deb5
FBSDKLoginKit: 699ff169080e3072de4b9b0faca90bf23dc36deb
FBSDKShareKit: 2fd887cce0056bdda91f99b2021d724a4fed8e88
FBSnapshotTestCase: 7e85180d0d141a0cf472352edda7e80d7eaeb547
NACrypto: ce3900f1775f1b0cc27ce7c4953b94c598a74149
NSDate_Utils: 68669d2c81f310ee13026c791f4f0ed227b94c65
@ -103,7 +103,7 @@ SPEC CHECKSUMS:
NSUserDefaults-AESEncryptor: da02cfef056f1e18ebe2748767915f08b274c9c5
nv-ios-http-status: b6c2b5fc8656cc19e0d3000dadce2080b99d0e2f
PEAR-FileManager-iOS: 3bc403f68a53483f5629aa822f4649e40275c4d3
PNObject: e3104b38e9aa668a992de191cb4630440cce5cf3
PNObject: 20b785cb5cbf88322f2c268a5ba80ca3337dec51
PureLayout: f35f5384c9c4e4479df041dbe33ad7577b71ddfb
Specta: ac94d110b865115fe60ff2c6d7281053c6f8e8a2
StrongestPasswordValidator: 921e42615bdf353513c6f925bffd4fc29865dbd7

View File

@ -41,5 +41,5 @@
#import <FBSDKCoreKit/FBSDKProfilePictureView.h>
#endif
#define FBSDK_VERSION_STRING @"4.10.0"
#define FBSDK_VERSION_STRING @"4.10.1"
#define FBSDK_TARGET_PLATFORM_VERSION @"v2.5"

View File

@ -41,39 +41,40 @@ static const u_int FB_GROUP1_RECHECK_DURATION = 30 * 60; // seconds
static const u_int FB_GIGABYTE = 1024 * 1024 * 1024; // bytes
@implementation FBSDKAppEventsDeviceInfo
{
// Ephemeral data, may change during the lifetime of an app. We collect them in different
// 'group' frequencies - group1 may gets collected once every 30 minutes.
// Ephemeral data, may change during the lifetime of an app. We collect them in different
// 'group' frequencies - group1 may gets collected once every 30 minutes.
// group1
NSString *_carrierName;
NSString *_timeZoneAbbrev;
unsigned long long _remainingDiskSpaceGB;
NSString *_timeZoneName;
// group1
NSString *_carrierName;
NSString *_timeZoneAbbrev;
unsigned long long _remainingDiskSpaceGB;
// Persistent data, but we maintain it to make rebuilding the device info as fast as possible.
NSString *_bundleIdentifier;
NSString *_longVersion;
NSString *_shortVersion;
NSString *_sysVersion;
NSString *_machine;
NSString *_language;
unsigned long long _totalDiskSpaceGB;
unsigned long long _coreCount;
CGFloat _width;
CGFloat _height;
CGFloat _density;
// Persistent data, but we maintain it to make rebuilding the device info as fast as possible.
NSString *_bundleIdentifier;
NSString *_longVersion;
NSString *_shortVersion;
NSString *_sysVersion;
NSString *_machine;
NSString *_language;
unsigned long long _totalDiskSpaceGB;
unsigned long long _coreCount;
CGFloat _width;
CGFloat _height;
CGFloat _density;
// Other state
long _lastGroup1CheckTime;
BOOL _isEncodingDirty = YES;
NSString *_encodedDeviceInfo;
static FBSDKAppEventsDeviceInfo *g_singleton;
// Other state
long _lastGroup1CheckTime;
BOOL _isEncodingDirty;
NSString *_encodedDeviceInfo;
}
#pragma mark - Public Methods
+ (void)extendDictionaryWithDeviceInfo:(NSMutableDictionary *)dictionary
{
dictionary[@"extinfo"] = [g_singleton encodedDeviceInfo];
dictionary[@"extinfo"] = [[self sharedDeviceInfo] encodedDeviceInfo];
}
#pragma mark - Internal Methods
@ -81,11 +82,27 @@ static FBSDKAppEventsDeviceInfo *g_singleton;
+ (void)initialize
{
if (self == [FBSDKAppEventsDeviceInfo class]) {
g_singleton = [[FBSDKAppEventsDeviceInfo alloc] init];
[g_singleton _collectPersistentData];
[[self sharedDeviceInfo] _collectPersistentData];
}
}
+ (instancetype)sharedDeviceInfo
{
static FBSDKAppEventsDeviceInfo *_sharedDeviceInfo = nil;
if (_sharedDeviceInfo == nil) {
_sharedDeviceInfo = [[FBSDKAppEventsDeviceInfo alloc] init];
}
return _sharedDeviceInfo;
}
- (instancetype)init
{
if ((self = [super init])) {
_isEncodingDirty = YES;
}
return self;
}
- (NSString *)encodedDeviceInfo
{
@synchronized (self) {
@ -168,9 +185,11 @@ static FBSDKAppEventsDeviceInfo *g_singleton;
}
// Time zone
NSString *newTimeZoneAbbrev = [[NSTimeZone systemTimeZone] abbreviation];
if (![newTimeZoneAbbrev isEqualToString:_timeZoneAbbrev]) {
_timeZoneAbbrev = newTimeZoneAbbrev;
NSTimeZone *timeZone = [NSTimeZone systemTimeZone];
NSString *timeZoneName = timeZone.name;
if (![timeZoneName isEqualToString:_timeZoneName]) {
_timeZoneName = timeZoneName;
_timeZoneAbbrev = timeZone.abbreviation;
_isEncodingDirty = YES;
}
@ -206,6 +225,7 @@ static FBSDKAppEventsDeviceInfo *g_singleton;
@(_coreCount) ?: @"",
@(_totalDiskSpaceGB) ?: @"",
@(_remainingDiskSpaceGB) ?: @"",
_timeZoneName ?: @""
];
return [FBSDKInternalUtility JSONStringForObject:arr error:NULL invalidObjectHandler:NULL];

View File

@ -1,6 +1,6 @@
{
"name": "PNObject",
"version": "0.4.5",
"version": "0.4.6",
"summary": "PNObject is a simple replica of the more complex ParseObject",
"homepage": "https://github.com/giuseppenucifora/PNObject",
"license": "MIT",
@ -9,7 +9,7 @@
},
"source": {
"git": "https://github.com/giuseppenucifora/PNObject.git",
"tag": "0.4.5"
"tag": "0.4.6"
},
"platforms": {
"ios": "8.0"

View File

@ -26,11 +26,11 @@ PODS:
- Expecta+Snapshots (2.0.0):
- Expecta (~> 1.0)
- FBSnapshotTestCase/Core (~> 2.0.3)
- FBSDKCoreKit (4.10.0):
- FBSDKCoreKit (4.10.1):
- Bolts (~> 1.5)
- FBSDKLoginKit (4.10.0):
- FBSDKLoginKit (4.10.1):
- FBSDKCoreKit
- FBSDKShareKit (4.10.0):
- FBSDKShareKit (4.10.1):
- FBSDKCoreKit
- FBSnapshotTestCase (2.0.7):
- FBSnapshotTestCase/SwiftSupport (= 2.0.7)
@ -44,7 +44,7 @@ PODS:
- CocoaSecurity (~> 1.2.2)
- nv-ios-http-status (0.0.1)
- PEAR-FileManager-iOS (1.3.1)
- PNObject (0.4.5):
- PNObject (0.4.6):
- AFNetworking
- CodFis-Helper
- FBSDKCoreKit
@ -93,9 +93,9 @@ SPEC CHECKSUMS:
CodFis-Helper: 28be4c74d7202542459d72354f59b1215871de87
Expecta: e1c022fcd33910b6be89c291d2775b3fe27a89fe
Expecta+Snapshots: 29b38dd695bc72a0ed2bea833937d78df41943ba
FBSDKCoreKit: 13bec8373fb3af94d44daf2aa1e0958687897fbd
FBSDKLoginKit: d3d4a2e9d31954deb00bfea964167a05ca1ea976
FBSDKShareKit: 54587b4624706ace1e810cf83412a918141f807a
FBSDKCoreKit: d2aaed5e9ab7d8d6301c533376a1fbff1cf3deb5
FBSDKLoginKit: 699ff169080e3072de4b9b0faca90bf23dc36deb
FBSDKShareKit: 2fd887cce0056bdda91f99b2021d724a4fed8e88
FBSnapshotTestCase: 7e85180d0d141a0cf472352edda7e80d7eaeb547
NACrypto: ce3900f1775f1b0cc27ce7c4953b94c598a74149
NSDate_Utils: 68669d2c81f310ee13026c791f4f0ed227b94c65
@ -103,7 +103,7 @@ SPEC CHECKSUMS:
NSUserDefaults-AESEncryptor: da02cfef056f1e18ebe2748767915f08b274c9c5
nv-ios-http-status: b6c2b5fc8656cc19e0d3000dadce2080b99d0e2f
PEAR-FileManager-iOS: 3bc403f68a53483f5629aa822f4649e40275c4d3
PNObject: e3104b38e9aa668a992de191cb4630440cce5cf3
PNObject: 20b785cb5cbf88322f2c268a5ba80ca3337dec51
PureLayout: f35f5384c9c4e4479df041dbe33ad7577b71ddfb
Specta: ac94d110b865115fe60ff2c6d7281053c6f8e8a2
StrongestPasswordValidator: 921e42615bdf353513c6f925bffd4fc29865dbd7

View File

@ -14,7 +14,7 @@
buildForArchiving = "YES">
<BuildableReference
BuildableIdentifier = 'primary'
BlueprintIdentifier = 'EEAC74642D33DB6F05CFDAD2'
BlueprintIdentifier = '24B6537E15CF8A8F679D4558'
BlueprintName = 'PNObject'
ReferencedContainer = 'container:Pods.xcodeproj'
BuildableName = 'PNObject.framework'>

View File

@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>4.10.0</string>
<string>4.10.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>

View File

@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>4.10.0</string>
<string>4.10.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>

View File

@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>4.10.0</string>
<string>4.10.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>

View File

@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.4.5</string>
<string>0.4.6</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>

View File

@ -274,11 +274,7 @@ static bool isFirstAccess = YES;
[[PNObjectConfig sharedInstance] refreshTokenForUserWithEmail:email password:password withBlockSuccess:^(BOOL refreshSuccess) {
if (refreshSuccess) {
if ([[self class] currentUser]) {
[[[self class] currentUser] resetUser];
}
PNUser *user = [[self class] currentUser];
PNUser *user = [[self class] new];
PNObjcPassword *objectPassword = [PNObjcPassword new];
[objectPassword setPassword:password];
@ -290,6 +286,8 @@ static bool isFirstAccess = YES;
[user saveLocally];
[user reloadFormServer];
USER = user;
if (success) {
success(user);
}