@automagik/omni 2.260617.2 → 2.260617.3

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 CHANGED
@@ -124971,7 +124971,7 @@ import { fileURLToPath } from "url";
124971
124971
  // package.json
124972
124972
  var package_default = {
124973
124973
  name: "@automagik/omni",
124974
- version: "2.260617.2",
124974
+ version: "2.260617.3",
124975
124975
  description: "LLM-optimized CLI for Omni",
124976
124976
  type: "module",
124977
124977
  bin: {
@@ -225245,7 +225245,7 @@ var init_sentry_scrub = __esm(() => {
225245
225245
  var require_package7 = __commonJS((exports, module) => {
225246
225246
  module.exports = {
225247
225247
  name: "@omni/api",
225248
- version: "2.260617.2",
225248
+ version: "2.260617.3",
225249
225249
  type: "module",
225250
225250
  exports: {
225251
225251
  ".": {
@@ -350897,7 +350897,11 @@ var init_chats2 = __esm(() => {
350897
350897
  const isAgentPaused = dbChat.settings?.agentPaused === true;
350898
350898
  if (isAgentPaused) {
350899
350899
  await services.chats.update(dbChat.id, {
350900
- settings: { agentPaused: false, agentResumedAt: new Date().toISOString() }
350900
+ settings: {
350901
+ ...dbChat.settings ?? {},
350902
+ agentPaused: false,
350903
+ agentResumedAt: new Date().toISOString()
350904
+ }
350901
350905
  });
350902
350906
  }
350903
350907
  }
@@ -357382,8 +357386,9 @@ var init_messages5 = __esm(() => {
357382
357386
  operation: "send handoff"
357383
357387
  });
357384
357388
  }
357389
+ const handoffChat = await services.chats.getById(data.chatId);
357385
357390
  await services.chats.update(data.chatId, {
357386
- settings: { agentPaused: true }
357391
+ settings: { ...handoffChat?.settings ?? {}, agentPaused: true }
357387
357392
  });
357388
357393
  await services.followUpLifecycle.disarm({
357389
357394
  chatId: data.chatId,
@@ -357481,8 +357486,10 @@ var init_messages5 = __esm(() => {
357481
357486
  const { terminal, escalated, closeUntil } = await computeCloseContactTerminalState(db2, data.chatId, outcome, auditRow?.id ?? null);
357482
357487
  const shouldPauseAgent = outcome === "lost";
357483
357488
  const closedAt = new Date;
357489
+ const closeChat = await services.chats.getById(data.chatId);
357484
357490
  await services.chats.update(data.chatId, {
357485
357491
  settings: {
357492
+ ...closeChat?.settings ?? {},
357486
357493
  ...shouldPauseAgent ? { agentPaused: true } : {},
357487
357494
  closed: terminal,
357488
357495
  closeUntil: closeUntil?.toISOString() ?? null,
@@ -357501,7 +357508,7 @@ var init_messages5 = __esm(() => {
357501
357508
  agentId: instance4.agentId ?? null,
357502
357509
  outcome,
357503
357510
  reason: data.reason ?? null,
357504
- escalated: terminal,
357511
+ escalated,
357505
357512
  closedFields: data.closeFields ?? null,
357506
357513
  closedAt: closedAt.toISOString()
357507
357514
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@automagik/omni",
3
- "version": "2.260617.2",
3
+ "version": "2.260617.3",
4
4
  "description": "LLM-optimized CLI for Omni",
5
5
  "type": "module",
6
6
  "bin": {