@xuda.io/account_module 1.2.1313 → 1.2.1315
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 +4 -4
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -189,7 +189,7 @@ export const update_account_info = async function (req, job_id, headers) {
|
|
|
189
189
|
// await drive_module.create_drive_folder_user({ ...drive_req, ...{ folder_name: 'Chat Thumbnails', is_system: true } }, job_id, headers);
|
|
190
190
|
// await drive_module.create_drive_folder_user({ ...drive_req, ...{ folder_name: 'Chat Attachments', is_system: true } }, job_id, headers);
|
|
191
191
|
|
|
192
|
-
const
|
|
192
|
+
const save_ret = await db_module.save_couch_doc('xuda_accounts', account_obj);
|
|
193
193
|
|
|
194
194
|
const ai_module = await import(`${module_path}/ai_module/index.mjs`);
|
|
195
195
|
if (account_obj.account_info?.profile_picture) {
|
|
@@ -202,10 +202,10 @@ export const update_account_info = async function (req, job_id, headers) {
|
|
|
202
202
|
|
|
203
203
|
// update_contacts_with_account_changes(account_obj._id, account_info_changes_arr);
|
|
204
204
|
|
|
205
|
-
if (
|
|
205
|
+
if (save_ret.code > 0) {
|
|
206
206
|
return { code: 1300, data: 'ok' };
|
|
207
207
|
}
|
|
208
|
-
return
|
|
208
|
+
return save_ret;
|
|
209
209
|
};
|
|
210
210
|
export const update_account_preferences = async function (req) {
|
|
211
211
|
const { uid, hide_create_button, default_dashboard, sidebar_style } = req;
|
|
@@ -585,7 +585,7 @@ export const get_active_account_profile_info = async function (uid) {
|
|
|
585
585
|
|
|
586
586
|
try {
|
|
587
587
|
} catch (error) {}
|
|
588
|
-
const account_profile_obj = await db_module.
|
|
588
|
+
const account_profile_obj = await db_module.get_app_couch_doc_native(acc_obj.account_project_id, active_account_profile_id);
|
|
589
589
|
if (account_profile_obj.share_item_id) {
|
|
590
590
|
// set the original profile id if shared
|
|
591
591
|
active_account_profile_id = account_profile_obj.share_item_id;
|