@hivegpt/hiveai-angular 0.0.303 → 0.0.304

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.
@@ -1280,7 +1280,8 @@ class ChatDrawerComponent {
1280
1280
  }
1281
1281
  // Toggle the dropdown visibility
1282
1282
  toggleDropdown() {
1283
- this.fetchAgents();
1283
+ if (!this.agents)
1284
+ this.fetchAgents();
1284
1285
  this.isDropdownOpen = !this.isDropdownOpen;
1285
1286
  this.cdr.detectChanges();
1286
1287
  }
@@ -1618,13 +1619,14 @@ class ChatDrawerComponent {
1618
1619
  }
1619
1620
  }
1620
1621
  makeAskRequest(inputMsg, agents, conversationId, msg, chat, workflowId, workflow_inputs) {
1622
+ var _a;
1621
1623
  var url = `${this.environment.BASE_URL}/ai/ask`;
1622
1624
  var body = {
1623
1625
  user_question: inputMsg,
1624
1626
  user_id: this.userId,
1625
1627
  bot_id: this.botId,
1626
1628
  message_id: this.conversationService.generateKey(),
1627
- agents: agents.filter((p) => p.selected).map((p) => p.id),
1629
+ agents: (_a = agents === null || agents === void 0 ? void 0 : agents.filter((p) => p.selected).map((p) => p.id)) !== null && _a !== void 0 ? _a : [],
1628
1630
  conversation_id: conversationId,
1629
1631
  };
1630
1632
  if (workflowId) {