xep_0454: Don't force content-type to application/octect-stream

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
Maxime “pep” Buquet 2022-03-18 18:30:58 +01:00
parent bde5aaaf3e
commit acad41f3b7

View File

@ -123,7 +123,7 @@ class XEP_0454(BasePlugin):
self, self,
filename: Path, filename: Path,
_size: Optional[int] = None, _size: Optional[int] = None,
_content_type: Optional[str] = None, content_type: Optional[str] = None,
**kwargs, **kwargs,
) -> str: ) -> str:
""" """
@ -154,7 +154,7 @@ class XEP_0454(BasePlugin):
input_enc.seek(0) input_enc.seek(0)
kwargs['size'] = size kwargs['size'] = size
kwargs['content_type'] = 'application/octet-stream' kwargs['content_type'] = content_type
url = await self.xmpp['xep_0363'].upload_file(**kwargs) url = await self.xmpp['xep_0363'].upload_file(**kwargs)
return self.format_url(url, fragment) return self.format_url(url, fragment)