@questionbase/deskfree 0.3.0-alpha.41 → 0.3.0-alpha.42
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.
- package/dist/index.js +4 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4827,6 +4827,7 @@ async function deliverMessageToAgent(ctx, message, client) {
|
|
|
4827
4827
|
});
|
|
4828
4828
|
let streamingSession = null;
|
|
4829
4829
|
let accumulatedText = "";
|
|
4830
|
+
const replyTaskId = message.taskId ?? getActiveTaskId() ?? void 0;
|
|
4830
4831
|
try {
|
|
4831
4832
|
const cfg = runtime.config.loadConfig();
|
|
4832
4833
|
const { dispatcher, replyOptions } = runtime.channel.reply.createReplyDispatcherWithTyping({
|
|
@@ -4840,7 +4841,7 @@ async function deliverMessageToAgent(ctx, message, client) {
|
|
|
4840
4841
|
log.warn("Deliver callback called with empty text, skipping.");
|
|
4841
4842
|
return;
|
|
4842
4843
|
}
|
|
4843
|
-
const taskId =
|
|
4844
|
+
const taskId = replyTaskId;
|
|
4844
4845
|
const kind = info?.kind ?? "final";
|
|
4845
4846
|
if (kind === "block") {
|
|
4846
4847
|
accumulatedText += text;
|
|
@@ -4878,7 +4879,7 @@ async function deliverMessageToAgent(ctx, message, client) {
|
|
|
4878
4879
|
}
|
|
4879
4880
|
}
|
|
4880
4881
|
});
|
|
4881
|
-
sendWsThinking(
|
|
4882
|
+
sendWsThinking(replyTaskId);
|
|
4882
4883
|
await runtime.channel.reply.dispatchReplyFromConfig({
|
|
4883
4884
|
ctx: msgCtx,
|
|
4884
4885
|
cfg,
|
|
@@ -8650,7 +8651,7 @@ var deskFreePlugin = {
|
|
|
8650
8651
|
const client = new DeskFreeClient(acct.botToken, acct.apiUrl);
|
|
8651
8652
|
const log = runtime.logging.createLogger("deskfree");
|
|
8652
8653
|
try {
|
|
8653
|
-
const taskId = ctx.threadId ? String(ctx.threadId) :
|
|
8654
|
+
const taskId = ctx.threadId ? String(ctx.threadId) : void 0;
|
|
8654
8655
|
await client.sendMessage({
|
|
8655
8656
|
content: ctx.text,
|
|
8656
8657
|
taskId
|