mirror of
https://github.com/TeamPGM/pyrogram.git
synced 2024-11-16 04:35:24 +00:00
Fix update_color enum
This commit is contained in:
parent
e102dc4445
commit
ece2217fed
@ -50,7 +50,7 @@ class UpdateColor:
|
||||
Example:
|
||||
.. code-block:: python
|
||||
|
||||
await app.update_color(chat_id, 1)
|
||||
await app.update_color(chat_id, enums.ProfileColor.RED)
|
||||
"""
|
||||
|
||||
peer = await self.resolve_peer(chat_id)
|
||||
@ -58,7 +58,7 @@ class UpdateColor:
|
||||
if isinstance(peer, raw.types.InputPeerSelf):
|
||||
await self.invoke(
|
||||
raw.functions.account.UpdateColor(
|
||||
color=color,
|
||||
color=color.value,
|
||||
background_emoji_id=background_emoji_id
|
||||
)
|
||||
)
|
||||
@ -69,7 +69,7 @@ class UpdateColor:
|
||||
r = await self.invoke(
|
||||
raw.functions.channels.UpdateColor(
|
||||
channel=peer,
|
||||
color=color,
|
||||
color=color.value,
|
||||
background_emoji_id=background_emoji_id
|
||||
)
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user