Support sending album with URL photos (#1681)

Fixes #1408.
This commit is contained in:
Googleplex 2021-01-25 15:31:25 +08:00 committed by GitHub
parent 65bf0e4c45
commit a886d609d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -406,7 +406,7 @@ class UploadMethods:
fh, fm, _ = await self._file_to_media( fh, fm, _ = await self._file_to_media(
file, supports_streaming=supports_streaming, file, supports_streaming=supports_streaming,
force_document=force_document) force_document=force_document)
if isinstance(fm, types.InputMediaUploadedPhoto): if isinstance(fm, (types.InputMediaUploadedPhoto, types.InputMediaPhotoExternal)):
r = await self(functions.messages.UploadMediaRequest( r = await self(functions.messages.UploadMediaRequest(
entity, media=fm entity, media=fm
)) ))