Skip to content

Commit

Permalink
Fixed crash when reloading Kite
Browse files Browse the repository at this point in the history
  • Loading branch information
Kostas Karayannis committed Jun 1, 2017
1 parent b12e3e2 commit 671b249
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Kite-Print-SDK.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = 'Kite-Print-SDK'
spec.version = '6.5.3'
spec.version = '6.5.4'
spec.license = { :type => 'MIT', :file => 'Kite-SDK/LICENSE' }
spec.homepage = 'https://github.com/OceanLabs/iOS-Print-SDK'
spec.authors = {'Deon Botha' => '[email protected]'}
Expand Down
3 changes: 3 additions & 0 deletions Kite-SDK/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
### 6.5.4
- Fixed crash when reloading Kite

### 6.5.3
- Handle Print at Home SDK delegate calls internally if OLKiteDelegate doesn’t handle them.
- First release of the Unity plugin
Expand Down
2 changes: 1 addition & 1 deletion Kite-SDK/PSPrintSDK/KiteCI-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>6.5.2</string>
<string>6.5.4</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
Expand Down
2 changes: 1 addition & 1 deletion Kite-SDK/PSPrintSDK/OLConstants.m
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

#import "OLConstants.h"

NSString *const kOLKiteSDKVersion = @"6.5.3";
NSString *const kOLKiteSDKVersion = @"6.5.4";
NSString *const kOLKiteSDKErrorDomain = @"co.oceanlabs.kOLKiteSDKErrorDomain";
NSString *const kNotificationTemplateSyncComplete = @"co.oceanlabs.pssdk.notification.kNotificationSyncComplete";
NSString *const kNotificationTemplateSyncPartialComplete = @"co.oceanlabs.pssdk.notification.kNotificationTemplateSyncPartialComplete";
Expand Down
18 changes: 13 additions & 5 deletions Kite-SDK/PSPrintSDK/OLKiteViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -481,17 +481,25 @@ - (void)templateSyncDidReturn:(NSNotification *)n{
if (!self.remoteThemePlistSyncOperation.finished && ![self.operationQueue.operations containsObject:self.remoteThemePlistSyncOperation]){
if ([OLKiteABTesting sharedInstance].userConfig[@"theme"]){
__weak OLKiteViewController *welf = self;
[[OLKiteABTesting sharedInstance] fetchRemotePlistsWithCompletionHandler:^{
[[OLKiteABTesting sharedInstance] fetchRemotePlistsWithCompletionHandler:^{
if (![welf.remoteThemePlistSyncOperation isExecuting] && ![welf.remoteThemePlistSyncOperation isFinished]){
[welf.remoteThemePlistSyncOperation addExecutionBlock:^{}];
}
if (![welf.remoteThemePlistSyncOperation isExecuting] && ![welf.remoteThemePlistSyncOperation isFinished]){
[welf.operationQueue addOperation:welf.remoteThemePlistSyncOperation];
}];
}
}];
}
else{
[self.remoteThemePlistSyncOperation addExecutionBlock:^{}];
[self.operationQueue addOperation:self.remoteThemePlistSyncOperation];
if (!self.remoteThemePlistSyncOperation.executing && !self.remoteThemePlistSyncOperation.finished){
[self.remoteThemePlistSyncOperation addExecutionBlock:^{}];
}
if (!self.remoteThemePlistSyncOperation.executing && !self.remoteThemePlistSyncOperation.finished){
[self.operationQueue addOperation:self.remoteThemePlistSyncOperation];
}
}
}
if (!self.templateSyncOperation.finished){
if (!self.templateSyncOperation.executing && !self.templateSyncOperation.finished){
[self.operationQueue addOperation:self.templateSyncOperation];
}

Expand Down

0 comments on commit 671b249

Please sign in to comment.