chore(communities): small cleanup in the communities module

This commit is contained in:
Jonathan Rainville 2023-06-15 16:13:07 -04:00
parent 347bc9c9d7
commit ccaa1578d0
4 changed files with 0 additions and 46 deletions

View File

@ -204,18 +204,6 @@ proc reorderCommunityChat*(
chatId,
position)
proc deleteCommunityChat*(
self: Controller,
communityId: string,
chatId: string) =
self.communityService.deleteCommunityChat(communityId, chatId)
proc deleteCommunityCategory*(
self: Controller,
communityId: string,
categoryId: string) =
self.communityService.deleteCommunityCategory(communityId, categoryId)
proc requestCommunityInfo*(self: Controller, communityId: string, importing: bool) =
self.communityService.requestCommunityInfo(communityId, importing)

View File

@ -49,15 +49,6 @@ method requestImportDiscordCommunity*(self: AccessInterface, name: string, descr
fromTimestamp: int) {.base.} =
raise newException(ValueError, "No implementation available")
method deleteCommunityCategory*(self: AccessInterface, communityId: string, categoryId: string) {.base.} =
raise newException(ValueError, "No implementation available")
method reorderCommunityCategories*(self: AccessInterface, communityId: string, categoryId: string, position: int) {.base} =
raise newException(ValueError, "No implementation available")
method reorderCommunityChannel*(self: AccessInterface, communityId: string, categoryId: string, chatId: string, position: int) {.base} =
raise newException(ValueError, "No implementation available")
method isUserMemberOfCommunity*(self: AccessInterface, communityId: string): bool {.base.} =
raise newException(ValueError, "No implementation available")
@ -76,9 +67,6 @@ method requestToJoinCommunity*(self: AccessInterface, communityId: string, ensNa
method requestCommunityInfo*(self: AccessInterface, communityId: string, importing: bool) {.base.} =
raise newException(ValueError, "No implementation available")
method deleteCommunityChat*(self: AccessInterface, communityId: string, channelId: string) {.base.} =
raise newException(ValueError, "No implementation available")
method importCommunity*(self: AccessInterface, communityKey: string) {.base.} =
raise newException(ValueError, "No implementation available")

View File

@ -264,13 +264,6 @@ method createCommunity*(self: Module, name: string,
imagePath, aX, aY, bX, bY, historyArchiveSupportEnabled, pinMessageAllMembersEnabled,
bannerJsonStr)
method deleteCommunityCategory*(self: Module, communityId: string, categoryId: string) =
self.controller.deleteCommunityCategory(communityId, categoryId)
method reorderCommunityCategories*(self: Module, communityId: string, categoryId: string, position: int) =
# self.controller.reorderCommunityCategories(communityId, categoryId, position)
discard
method communityMuted*(self: Module, communityId: string, muted: bool) =
self.view.model().setMuted(communityId, muted)
@ -321,9 +314,6 @@ method userCanJoin*(self: Module, communityId: string): bool =
method isCommunityRequestPending*(self: Module, communityId: string): bool =
self.controller.isCommunityRequestPending(communityId)
method deleteCommunityChat*(self: Module, communityId: string, channelId: string) =
self.controller.deleteCommunityChat(communityId, channelId)
method communityImported*(self: Module, community: CommunityDto) =
self.view.addItem(self.getCommunityItem(community))
self.view.emitImportingCommunityStateChangedSignal(community.id, ImportCommunityState.Imported.int, errorMsg = "")

View File

@ -464,15 +464,6 @@ QtObject:
imagePath, aX, aY, bX, bY, historyArchiveSupportEnabled, pinMessageAllMembersEnabled,
filesToImport, fromTimestamp)
proc deleteCommunityCategory*(self: View, communityId: string, categoryId: string): string {.slot.} =
self.delegate.deleteCommunityCategory(communityId, categoryId)
proc reorderCommunityCategories*(self: View, communityId: string, categoryId: string, position: int) {.slot} =
self.delegate.reorderCommunityCategories(communityId, categoryId, position)
proc reorderCommunityChannel*(self: View, communityId: string, categoryId: string, chatId: string, position: int): string {.slot} =
self.delegate.reorderCommunityChannel(communityId, categoryId, chatId, position)
proc cancelRequestToJoinCommunity*(self: View, communityId: string) {.slot.} =
self.delegate.cancelRequestToJoinCommunity(communityId)
@ -504,9 +495,6 @@ QtObject:
proc isCommunityRequestPending*(self: View, communityId: string): bool {.slot.} =
self.delegate.isCommunityRequestPending(communityId)
proc deleteCommunityChat*(self: View, communityId: string, channelId: string) {.slot.} =
self.delegate.deleteCommunityChat(communityId, channelId)
proc importCommunity*(self: View, communityKey: string) {.slot.} =
self.delegate.importCommunity(communityKey)