mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-22 04:21:44 +00:00
hotfix(community): fix missing function
This commit is contained in:
parent
bed7ca20fb
commit
4f706e8b21
@ -112,6 +112,20 @@ QtObject:
|
|||||||
self.joinedCommunities[membershipRequest.communityId] = community
|
self.joinedCommunities[membershipRequest.communityId] = community
|
||||||
self.events.emit(SIGNAL_COMMUNITY_EDITED, CommunityArgs(community: community))
|
self.events.emit(SIGNAL_COMMUNITY_EDITED, CommunityArgs(community: community))
|
||||||
|
|
||||||
|
proc mapChatToChatDto(chat: Chat, communityId: string): ChatDto =
|
||||||
|
result = ChatDto()
|
||||||
|
result.id = chat.id
|
||||||
|
result.communityId = communityId
|
||||||
|
result.name = chat.name
|
||||||
|
result.chatType = ChatType.CommunityChat
|
||||||
|
result.color = chat.color
|
||||||
|
result.emoji = chat.emoji
|
||||||
|
result.description = chat.description
|
||||||
|
result.canPost = chat.canPost
|
||||||
|
result.position = chat.position
|
||||||
|
result.categoryId = chat.categoryId
|
||||||
|
result.communityId = communityId
|
||||||
|
|
||||||
proc updateMissingFields(chatDto: var ChatDto, chat: Chat) =
|
proc updateMissingFields(chatDto: var ChatDto, chat: Chat) =
|
||||||
# This proc sets fields of `chatDto` which are available only for comminity channels.
|
# This proc sets fields of `chatDto` which are available only for comminity channels.
|
||||||
chatDto.position = chat.position
|
chatDto.position = chat.position
|
||||||
|
Loading…
x
Reference in New Issue
Block a user