mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-05-19 14:12:13 +02:00
An uploaded video is stored in the media cache to avoid downloading it later again
This commit is contained in:
@@ -1080,7 +1080,12 @@ NSString *const kCmdResetUserPowerLevel = @"/deop";
|
||||
|
||||
MediaLoader *videoUploader = [MediaManager prepareUploaderWithId:localEvent.eventId initialRange:0.1 andRange:0.9];
|
||||
[videoUploader uploadData:videoData mimeType:videoInfo[@"mimetype"] success:^(NSString *url) {
|
||||
// remove the related uploadLoader
|
||||
[MediaManager removeUploaderWithId:localEvent.eventId];
|
||||
// store the video file in the cache
|
||||
// there is no reason to download an oneself uploaded media
|
||||
[MediaManager cacheMediaData:videoData forURL:url andType:videoInfo[@"mimetype"]];
|
||||
|
||||
[videoContent setValue:url forKey:@"url"];
|
||||
[videoContent setValue:videoInfo forKey:@"info"];
|
||||
[videoContent setValue:@"Video" forKey:@"body"];
|
||||
|
||||
Reference in New Issue
Block a user