@openclaw/discord 2026.2.6 → 2026.2.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/channel.ts +11 -4
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/discord",
3
- "version": "2026.2.6",
3
+ "version": "2026.2.9",
4
4
  "description": "OpenClaw Discord channel plugin",
5
5
  "type": "module",
6
6
  "devDependencies": {
package/src/channel.ts CHANGED
@@ -31,10 +31,17 @@ import { getDiscordRuntime } from "./runtime.js";
31
31
  const meta = getChatChannelMeta("discord");
32
32
 
33
33
  const discordMessageActions: ChannelMessageActionAdapter = {
34
- listActions: (ctx) => getDiscordRuntime().channel.discord.messageActions.listActions(ctx),
35
- extractToolSend: (ctx) => getDiscordRuntime().channel.discord.messageActions.extractToolSend(ctx),
36
- handleAction: async (ctx) =>
37
- await getDiscordRuntime().channel.discord.messageActions.handleAction(ctx),
34
+ listActions: (ctx) =>
35
+ getDiscordRuntime().channel.discord.messageActions?.listActions?.(ctx) ?? [],
36
+ extractToolSend: (ctx) =>
37
+ getDiscordRuntime().channel.discord.messageActions?.extractToolSend?.(ctx) ?? null,
38
+ handleAction: async (ctx) => {
39
+ const ma = getDiscordRuntime().channel.discord.messageActions;
40
+ if (!ma?.handleAction) {
41
+ throw new Error("Discord message actions not available");
42
+ }
43
+ return ma.handleAction(ctx);
44
+ },
38
45
  };
39
46
 
40
47
  export const discordPlugin: ChannelPlugin<ResolvedDiscordAccount> = {