@xuda.io/ai_module 1.1.5496 → 1.1.5498
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/index.mjs +2 -6
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -5112,16 +5112,12 @@ const ai_chat_conversation = async function (req, job_id, headers) {
|
|
|
5112
5112
|
}
|
|
5113
5113
|
};
|
|
5114
5114
|
|
|
5115
|
-
const add_conversation_item = async function (uid, profile_id, text, conversation_type, contact_id, metadata = {}) {
|
|
5115
|
+
const add_conversation_item = async function (uid, profile_id, conversation_id, text, conversation_type, contact_id, metadata = {}) {
|
|
5116
5116
|
const account_profile_info = await get_active_account_profile_info(uid, profile_id);
|
|
5117
5117
|
|
|
5118
5118
|
try {
|
|
5119
|
-
|
|
5120
|
-
|
|
5121
|
-
const sender_app_id = account_profile_info.app_id; //await get_account_default_project_id(uid);
|
|
5122
|
-
let sender_conversation_doc = await db_module.get_app_couch_doc_native(sender_app_id, conversation_id);
|
|
5119
|
+
let conversation_doc = await db_module.get_app_couch_doc_native(account_profile_info.app_id, conversation_id);
|
|
5123
5120
|
|
|
5124
|
-
await attachment_handler(uid, sender_app_id, conversation_id, attachments, account_profile_info);
|
|
5125
5121
|
let item;
|
|
5126
5122
|
try {
|
|
5127
5123
|
item = await client.conversations.items.create(conversation_doc.reference_conversation_id, {
|