diff --git a/Apptentive/Apptentive/Apptentive.h b/Apptentive/Apptentive/Apptentive.h index 3dbd1b4f8..ff76ce752 100644 --- a/Apptentive/Apptentive/Apptentive.h +++ b/Apptentive/Apptentive/Apptentive.h @@ -20,7 +20,7 @@ FOUNDATION_EXPORT double ApptentiveVersionNumber; FOUNDATION_EXPORT const unsigned char ApptentiveVersionString[]; /** The version number of the Apptentive SDK. */ -#define kApptentiveVersionString @"4.1.0" +#define kApptentiveVersionString @"4.1.1" /** The version number of the Apptentive API platform. */ #define kApptentiveAPIVersionString @"9" diff --git a/Apptentive/Apptentive/Apptentive.storyboard b/Apptentive/Apptentive/Apptentive.storyboard index 7c1d4ad32..d438e88a8 100644 --- a/Apptentive/Apptentive/Apptentive.storyboard +++ b/Apptentive/Apptentive/Apptentive.storyboard @@ -1,15 +1,16 @@ - + - + + @@ -818,6 +819,7 @@ + @@ -906,10 +908,6 @@ - - - - @@ -933,12 +931,13 @@ - + - + + @@ -960,10 +959,6 @@ - - - - @@ -1018,9 +1013,10 @@ - - + + + @@ -1051,10 +1047,6 @@ - - - - @@ -1103,14 +1095,15 @@ Your feedback is hosted by Apptentive and is subject to both Apptentive’s priv - + - + - + + @@ -1166,10 +1159,6 @@ Your feedback is hosted by Apptentive and is subject to both Apptentive’s priv - - - - @@ -1247,21 +1236,22 @@ Your feedback is hosted by Apptentive and is subject to both Apptentive’s priv - + - + - + - + - + + @@ -1832,6 +1822,7 @@ Lines + @@ -1866,6 +1857,7 @@ Lines + diff --git a/Apptentive/Apptentive/Misc/ApptentiveLogMonitor.m b/Apptentive/Apptentive/Misc/ApptentiveLogMonitor.m index ddcc8dd6a..67603a053 100644 --- a/Apptentive/Apptentive/Misc/ApptentiveLogMonitor.m +++ b/Apptentive/Apptentive/Misc/ApptentiveLogMonitor.m @@ -306,7 +306,12 @@ + (NSDictionary *)loadJsonFromURL:(NSURL *)URL body:(NSData *)body headers:(NSDi NSURLResponse *response; NSError *requestError; + +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" NSData *data = [NSURLConnection sendSynchronousRequest:request returningResponse:&response error:&requestError]; +#pragma clang diagnostic pop + if (requestError != nil) { ApptentiveLogError(@"Unable to load json from URL: %@", requestError); return nil; @@ -372,8 +377,13 @@ + (nullable ApptentiveLogMonitorConfigration *)readConfigurationFromToken:(NSStr - (void)sendReportWithAttachedFiles:(NSArray *)files { if (![MFMailComposeViewController canSendMail]) { + +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"Apptentive Log Monitor" message:@"Unable to send email" delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil]; [alertView show]; +#pragma clang diagnostic pop + return; } diff --git a/Apptentive/Apptentive/Network Queue/ApptentiveRequestOperation.m b/Apptentive/Apptentive/Network Queue/ApptentiveRequestOperation.m index 2736585ef..d9a8213a3 100644 --- a/Apptentive/Apptentive/Network Queue/ApptentiveRequestOperation.m +++ b/Apptentive/Apptentive/Network Queue/ApptentiveRequestOperation.m @@ -108,7 +108,7 @@ - (void)startTask { [self willChangeValueForKey:@"isExecuting"]; _task = [self.dataSource.URLSession dataTaskWithRequest:self.URLRequest completionHandler:^(NSData *_Nullable data, NSURLResponse *_Nullable response, NSError *_Nullable error) { - if (self.isCancelled) { + if (self.isCancelled || error.code == NSURLErrorCancelled) { return; } else if (!response) { [self processNetworkError:error]; @@ -156,6 +156,7 @@ - (void)cancel { BOOL shouldFinish = self.isExecuting; [self willChangeValueForKey:@"isCancelled"]; + _wasCancelled = YES; [self.task cancel]; [self didChangeValueForKey:@"isCancelled"]; diff --git a/CHANGELOG.md b/CHANGELOG.md index 770da92a4..b7350ef6a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +2017-11-13 frankus, weeebox v4.1.1 +---------------------------------- +###Bugs Fixed + +- Fix rare crash in ApptentivePayloadSender when a request is cancelled +- Fix About Apptentive and Upgrade Message layout on iPhone X + 2017-11-06 frankus, weeebox v4.1.0 ---------------------------------- ###Improvements diff --git a/Example/Example.xcodeproj/xcshareddata/xcschemes/iOSExample.xcscheme b/Example/Example.xcodeproj/xcshareddata/xcschemes/iOSExample.xcscheme new file mode 100644 index 000000000..f165b6287 --- /dev/null +++ b/Example/Example.xcodeproj/xcshareddata/xcschemes/iOSExample.xcscheme @@ -0,0 +1,93 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Example/Podfile.lock b/Example/Podfile.lock index 8ba4f86b9..791ff684f 100644 --- a/Example/Podfile.lock +++ b/Example/Podfile.lock @@ -1,5 +1,5 @@ PODS: - - apptentive-ios (4.0.0) + - apptentive-ios (4.1.1) DEPENDENCIES: - apptentive-ios (from `..`) @@ -9,8 +9,8 @@ EXTERNAL SOURCES: :path: .. SPEC CHECKSUMS: - apptentive-ios: 23ee8c1cf5fddc33f471922f152ef5e75d8f8199 + apptentive-ios: 6d5f7108a509e5ce904694d4d778de1ccb8c7f95 -PODFILE CHECKSUM: d9f8c76e781b9e490f735f6b0369a9f3d1c4fd0e +PODFILE CHECKSUM: fb7822acbd17e9b6c60d2db75808647cc370b6a0 -COCOAPODS: 1.3.0.beta.2 +COCOAPODS: 1.3.1 diff --git a/Example/podfile b/Example/podfile index 6e1665d21..b0ccc4663 100644 --- a/Example/podfile +++ b/Example/podfile @@ -1,4 +1,4 @@ -platform :ios, '8.0' +platform :ios, '9.0' use_frameworks! target 'iOSExample' do diff --git a/apptentive-ios.podspec b/apptentive-ios.podspec index fc36822ab..4dddf5b5f 100644 --- a/apptentive-ios.podspec +++ b/apptentive-ios.podspec @@ -1,13 +1,13 @@ Pod::Spec.new do |s| s.name = 'apptentive-ios' s.module_name = 'Apptentive' - s.version = '4.1.0' + s.version = '4.1.1' s.license = 'BSD' s.summary = 'Apptentive Customer Communications SDK.' s.homepage = 'https://www.apptentive.com/' s.authors = { 'Apptentive SDK Team' => 'sdks@apptentive.com' } s.source = { :git => 'https://github.com/apptentive/apptentive-ios.git', :tag => "v#{s.version}" } - s.platform = :ios, '8.0' + s.platform = :ios, '9.0' s.source_files = 'Apptentive/Apptentive/**/*.{h,m}' s.requires_arc = true s.frameworks = 'AVFoundation', 'CoreData', 'CoreGraphics', 'Foundation', 'ImageIO', 'MobileCoreServices', 'QuartzCore', 'QuickLook', 'SystemConfiguration', 'UIKit'