mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-21 17:12:45 +02:00
Delete video files in temp folder when the upload is done or has failed
This commit is contained in:
@@ -2693,19 +2693,29 @@ static CGSize kThreadListBarButtonItemImageSize;
|
||||
}
|
||||
}
|
||||
|
||||
// bwi: 5365
|
||||
- (void)sendVideoAssetWithoutCompression:(AVAsset *)videoAsset isPhotoLibraryAsset:(BOOL)isPhotoLibraryAsset
|
||||
{
|
||||
// Create before sending the message in case of a discussion (direct chat)
|
||||
[self createDiscussionIfNeeded:^(BOOL readyToSend) {
|
||||
if (readyToSend && [self inputToolbarConformsToToolbarViewProtocol])
|
||||
{
|
||||
[self.inputToolbarView sendSelectedVideoAsset:videoAsset isPhotoLibraryAsset:isPhotoLibraryAsset];
|
||||
if(![self.inputToolbarView sendSelectedVideoAsset:videoAsset isPhotoLibraryAsset:isPhotoLibraryAsset]) {
|
||||
NSURL *url = [(AVURLAsset *)videoAsset URL];
|
||||
if(url) {
|
||||
[self deleteFileAtURL:url];
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if([videoAsset isKindOfClass:[AVURLAsset class]]) {
|
||||
NSURL *url = [(AVURLAsset *)videoAsset URL];
|
||||
[self deleteFileAtURL:url];
|
||||
}
|
||||
}
|
||||
NSURL *url = [(AVURLAsset *)videoAsset URL];
|
||||
if(url) {
|
||||
[self deleteFileAtURL:url];
|
||||
}
|
||||
}];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user