Async function -> return awaitable
This commit is contained in:
parent
d7b0b9013f
commit
d116ebefc7
|
@ -148,26 +148,26 @@ class Puppet(DBPuppet, BasePuppet):
|
||||||
|
|
||||||
# region User info updating
|
# region User info updating
|
||||||
|
|
||||||
async def update_info_from_participant(
|
def update_info_from_participant(
|
||||||
self,
|
self,
|
||||||
source: u.User,
|
source: u.User,
|
||||||
info: UserInfoUnion,
|
info: UserInfoUnion,
|
||||||
update_avatar: bool = True,
|
update_avatar: bool = True,
|
||||||
) -> Puppet:
|
) -> Awaitable[Puppet]:
|
||||||
await self._update_info(
|
return self._update_info(
|
||||||
source,
|
source,
|
||||||
info.nickname,
|
info.nickname,
|
||||||
info.profileURL,
|
info.profileURL,
|
||||||
update_avatar
|
update_avatar
|
||||||
)
|
)
|
||||||
|
|
||||||
async def update_info_from_friend(
|
def update_info_from_friend(
|
||||||
self,
|
self,
|
||||||
source: u.User,
|
source: u.User,
|
||||||
info: FriendStruct,
|
info: FriendStruct,
|
||||||
update_avatar: bool = True,
|
update_avatar: bool = True,
|
||||||
) -> Puppet:
|
) -> Awaitable[Puppet]:
|
||||||
await self._update_info(
|
return self._update_info(
|
||||||
source,
|
source,
|
||||||
info.nickName,
|
info.nickName,
|
||||||
info.profileImageUrl,
|
info.profileImageUrl,
|
||||||
|
|
Loading…
Reference in New Issue