@xuda.io/ai_module 1.1.5528 → 1.1.5529

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/index.mjs +5 -6
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -3855,9 +3855,9 @@ const contact_chat_conversation = async function (req, job_id, headers) {
3855
3855
  const sender_app_id = account_profile_info.app_id;
3856
3856
  let sender_conversation_doc = await db_module.get_app_couch_doc_native(sender_app_id, conversation_id);
3857
3857
 
3858
- let
3858
+ let conversation_item_reference_id;
3859
3859
  try {
3860
- const conversation_item_reference_id=await add_conversation_item(uid, profile_id, conversation_id, prompt, 'chat', conversation_doc.reference_id, { direction: 'out' });
3860
+ conversation_item_reference_id = await add_conversation_item(uid, profile_id, conversation_id, prompt, 'chat', conversation_doc.reference_id, { direction: 'out' });
3861
3861
 
3862
3862
  report_ai_status('conversations');
3863
3863
  } catch (err) {
@@ -4032,7 +4032,6 @@ const chat_email = async function (req, job_id, headers) {
4032
4032
  throw err;
4033
4033
  }
4034
4034
 
4035
-
4036
4035
  await db_module.save_app_couch_doc_native(sender_app_id, sender_conversation_doc);
4037
4036
 
4038
4037
  let out_conversation_item_obj = {
@@ -5121,9 +5120,9 @@ const add_conversation_item = async function (uid, profile_id, conversation_id,
5121
5120
  },
5122
5121
  ];
5123
5122
 
5124
- let item
5123
+ let item;
5125
5124
  try {
5126
- item = await client.conversations.items.create(conversation_doc.reference_conversation_id, {
5125
+ item = await client.conversations.items.create(conversation_doc.reference_conversation_id, {
5127
5126
  items,
5128
5127
  });
5129
5128
  } catch (err) {
@@ -5140,7 +5139,7 @@ const add_conversation_item = async function (uid, profile_id, conversation_id,
5140
5139
  }
5141
5140
  }
5142
5141
 
5143
- return item.data[0].id
5142
+ return item.data[0].id;
5144
5143
  } catch (err) {
5145
5144
  throw err;
5146
5145
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/ai_module",
3
- "version": "1.1.5528",
3
+ "version": "1.1.5529",
4
4
  "description": "Xuda AI Module",
5
5
  "main": "index.mjs",
6
6
  "type": "module",