From 43b799391a7f498bec799da28bbd0fddeefff20d Mon Sep 17 00:00:00 2001 From: Shadow Date: Thu, 12 Feb 2026 16:45:39 -0600 Subject: [PATCH] fix: add Discord channel-edit thread params (#5542) (thanks @stumct) --- CHANGELOG.md | 1 + .../actions/discord/handle-action.test.ts | 23 +++++++++++++++++++ 2 files changed, 24 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8f5a54ea58..700838c8c0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -65,6 +65,7 @@ Docs: https://docs.openclaw.ai - Agents: prevent file descriptor leaks in child process cleanup. (#13565) Thanks @KyleChen26. - Agents: prevent double compaction caused by cache TTL bypassing guard. (#13514) Thanks @taw0002. - Agents: use last API call's cache tokens for context display instead of accumulated sum. (#13805) Thanks @akari-musubi. +- Discord: allow channel-edit to archive/lock threads and set auto-archive duration. (#5542) Thanks @stumct. - Discord tests: use a partial @buape/carbon mock in slash command coverage. (#13262) Thanks @arosstale. - Tests: update thread ID handling in Slack message collection tests. (#14108) Thanks @swizzmagik. diff --git a/src/channels/plugins/actions/discord/handle-action.test.ts b/src/channels/plugins/actions/discord/handle-action.test.ts index 927f6fdcbd..425c7d5a50 100644 --- a/src/channels/plugins/actions/discord/handle-action.test.ts +++ b/src/channels/plugins/actions/discord/handle-action.test.ts @@ -32,4 +32,27 @@ describe("handleDiscordMessageAction", () => { expect.any(Object), ); }); + + it("forwards thread edit fields for channel-edit", async () => { + await handleDiscordMessageAction({ + action: "channel-edit", + params: { + channelId: "123456789", + archived: true, + locked: false, + autoArchiveDuration: 1440, + }, + cfg: {}, + }); + expect(handleDiscordAction).toHaveBeenCalledWith( + expect.objectContaining({ + action: "channelEdit", + channelId: "123456789", + archived: true, + locked: false, + autoArchiveDuration: 1440, + }), + expect.any(Object), + ); + }); });