summary refs log tree commit diff
path: root/api/src/routes/channels
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-09-20 18:34:13 +0200
committerGitHub <noreply@github.com>2021-09-20 18:34:13 +0200
commit3151e904484feeaffd4eb67bfb978591957c3c13 (patch)
tree38f774cfae5f41b831d043c6e46855ec14e2ad15 /api/src/routes/channels
parentMerge branch 'master' of https://github.com/fosscord/fosscord-api (diff)
parentUpdate index.ts (diff)
downloadserver-3151e904484feeaffd4eb67bfb978591957c3c13.tar.xz
Merge pull request #386 from ChrisChrome/master
Delete messages before deleting channel
Diffstat (limited to 'api/src/routes/channels')
-rw-r--r--api/src/routes/channels/#channel_id/index.ts1
1 files changed, 0 insertions, 1 deletions
diff --git a/api/src/routes/channels/#channel_id/index.ts b/api/src/routes/channels/#channel_id/index.ts

index 3f434f5e..fde75ec9 100644 --- a/api/src/routes/channels/#channel_id/index.ts +++ b/api/src/routes/channels/#channel_id/index.ts
@@ -30,7 +30,6 @@ router.delete("/", route({ permission: "MANAGE_CHANNELS" }), async (req: Request } else if (channel.type === ChannelType.GROUP_DM) { await Channel.removeRecipientFromChannel(channel, req.user_id) } else { - //TODO messages in this channel should be deleted before deleting the channel await Promise.all([ Channel.delete({ id: channel_id }), emitEvent({ event: "CHANNEL_DELETE", data: channel, channel_id } as ChannelDeleteEvent)