fix: allow POST /users/@me/channels with recipient_id 0 (#1160)

This commit is contained in:
dogbonewish authored and GitHub committed 2026-06-24 23:11:29 +01:00
1 parent a45693f581
commit 41ec2544cf
4 files changed
+50 -4

No files matched your search

@@ -79,4 +79,11 @@ describe('CreatePrivateChannelRequest', () => {
);
expect(CreatePrivateChannelRequest.safeParse({recipients}).success).toBe(false);
});
it('allows DM requests to the system user id 0', () => {
const parsed = CreatePrivateChannelRequest.safeParse({recipient_id: '0'});
expect(parsed.success).toBe(true);
if (parsed.success) {
expect(parsed.data.recipient_id).toBe(0n);
}
});
});