mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 01:20:12 +00:00
Pass attachment bodies when loading media
This commit is contained in:
committed by
Stefan Ceriu
parent
95492d7e10
commit
86aebfb9ef
@@ -46,9 +46,9 @@ actor MediaLoader: MediaLoaderProtocol {
|
||||
}
|
||||
}
|
||||
|
||||
func loadMediaFileForSource(_ source: MediaSourceProxy) async throws -> MediaFileHandleProxy {
|
||||
func loadMediaFileForSource(_ source: MediaSourceProxy, body: String?) async throws -> MediaFileHandleProxy {
|
||||
let result = try await Task.dispatch(on: clientQueue) {
|
||||
try self.client.getMediaFile(mediaSource: source.underlyingSource, mimeType: source.mimeType ?? "application/octet-stream")
|
||||
try self.client.getMediaFile(mediaSource: source.underlyingSource, body: body, mimeType: source.mimeType ?? "application/octet-stream")
|
||||
}
|
||||
|
||||
return MediaFileHandleProxy(handle: result)
|
||||
|
||||
Reference in New Issue
Block a user