Skip to content

Commit

Permalink
Clean build
Browse files Browse the repository at this point in the history
  • Loading branch information
MMasterson committed May 18, 2017
1 parent aad2008 commit bc6dc12
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 11 deletions.
4 changes: 2 additions & 2 deletions Pod/Classes/TUSAssetData.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@

#if TARGET_OS_IPHONE
#import <AssetsLibrary/AssetsLibrary.h>
#elif TARGET_OS_MAC
#elif defined TARGET_OS_OSX
@import MediaLibrary;
#endif

@interface TUSAssetData : TUSData

#if TARGET_OS_IPHONE
- (id)initWithAsset:(ALAsset*)asset;
#elif TARGET_OS_MAC
#elif defined TARGET_OS_OSX
- (id)initWithAsset:(MLMediaObject*)asset;
#endif

Expand Down
11 changes: 7 additions & 4 deletions Pod/Classes/TUSAssetData.m
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
@interface TUSAssetData ()
#if TARGET_OS_IPHONE
@property (strong, nonatomic) ALAsset* asset;
#elif TARGET_OS_MAC
#elif defined TARGET_OS_OSX
@property (strong, nonatomic) MLMediaObject* asset;
#endif
@end
Expand All @@ -30,7 +30,8 @@ - (id)initWithAsset:(ALAsset*)asset
}
return self;
}
#ELIF TARGET_OS_MAC
#endif
#if TARGET_OS_OSX
- (id)initWithAsset:(MLMediaObject*)asset
{
self = [super init];
Expand Down Expand Up @@ -62,7 +63,8 @@ - (long long)length

return [assetRepresentation size];
}
#ELIF TARGET_OS_MAC
#endif
#if TARGET_OS_OSX
- (long long)length
{
if (!_asset) {
Expand Down Expand Up @@ -93,7 +95,8 @@ - (NSUInteger)getBytes:(uint8_t *)buffer
length:length
error:error];
}
#ELIF TARGET_OS_MAC
#endif
#if TARGET_OS_OSX
#endif


Expand Down
8 changes: 4 additions & 4 deletions Pod/Classes/TUSResumableUpload.m
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ - (BOOL)createFile
#if TARGET_OS_IPHONE
UIBackgroundTaskIdentifier bgTask = [[UIApplication sharedApplication] beginBackgroundTaskWithExpirationHandler:^{
[weakself cancel];
}]; #elif TARGET_OS_MAC
}];
#endif

self.currentTask = [self.delegate.session dataTaskWithRequest:request completionHandler:^(NSData * _Nullable data, NSURLResponse * _Nullable response, NSError * _Nullable error){
Expand Down Expand Up @@ -348,7 +348,7 @@ - (BOOL)createFile
[weakself.delegate saveUpload:weakself]; // Save current state for reloading - only save when we get a call back, not at the start of one (because this is the only time the state changes)
#if TARGET_OS_IPHONE
[[UIApplication sharedApplication] endBackgroundTask:bgTask];
#elif TARGET_OS_MAC
#elif defined TARGET_OS_OSX
[weakself cancel];
#endif

Expand Down Expand Up @@ -454,7 +454,7 @@ - (BOOL) checkFile
[weakself.delegate saveUpload:weakself]; // Save current state for reloading - only save when we get a call back, not at the start of one (because this is the only time the state changes)
#if TARGET_OS_IPHONE
[[UIApplication sharedApplication] endBackgroundTask:bgTask];
#elif TARGET_OS_MAC
#elif defined TARGET_OS_OSX
[weakself cancel];
#endif
if (delayTime > 0) {
Expand Down Expand Up @@ -542,7 +542,7 @@ -(BOOL)uploadFile
[weakself.delegate saveUpload:weakself]; // Save current state for reloading - only save when we get a call back, not at the start of one (because this is the only time the state changes)
#if TARGET_OS_IPHONE
[[UIApplication sharedApplication] endBackgroundTask:bgTask];
#elif TARGET_OS_MAC
#elif defined TARGET_OS_OSX
[weakself cancel];
#endif
[weakself continueUpload]; // Continue upload, not resume, because we do not want to continue if cancelled.
Expand Down
2 changes: 1 addition & 1 deletion TUSKit.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "TUSKit"
s.version = "1.3.9"
s.version = "1.3.10"
s.summary = "An iOS implementation of the tus resumable video upload protocol."
s.description = <<-DESC
An iOS implementation of the tus resumable video upload protocol.
Expand Down

0 comments on commit bc6dc12

Please sign in to comment.