@xuda.io/ai_module 1.1.3624 → 1.1.3626
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 +6 -7
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -5860,14 +5860,13 @@ export const create_ai_agent_image = async function (req, job_id, headers) {
|
|
|
5860
5860
|
const drive_ret = await drive_module.upload_drive_file_studio({ uid, app_id, path: '/Progs Thumbnails' }, job_id, headers, file_obj);
|
|
5861
5861
|
|
|
5862
5862
|
if (drive_ret.code > 0) {
|
|
5863
|
-
let db_doc = await db_module.
|
|
5864
|
-
db_doc.
|
|
5865
|
-
db_doc.
|
|
5866
|
-
|
|
5867
|
-
|
|
5868
|
-
const save_ret = await db_module.save_couch_doc_native('xuda_accounts', db_doc);
|
|
5863
|
+
let db_doc = await db_module.get_app_couch_doc_native(app_id, ai_agent_id);
|
|
5864
|
+
db_doc.studio_meta.thumbnail_request_ts = Date.now();
|
|
5865
|
+
db_doc.studio_meta.agent_image = drive_ret.data;
|
|
5866
|
+
|
|
5867
|
+
const save_ret = await db_module.save_app_couch_doc_native(app_id, db_doc);
|
|
5869
5868
|
console.log(save_ret);
|
|
5870
|
-
|
|
5869
|
+
|
|
5871
5870
|
return save_ret;
|
|
5872
5871
|
// account_module.update_contacts_with_account_changes(db_doc._id, ['profile_avatar']);
|
|
5873
5872
|
} else {
|