@xuda.io/account_module 1.2.1463 → 1.2.1465

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 -4
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -195,8 +195,9 @@ export const update_account_info = async function (req, job_id, headers) {
195
195
  const ai_module = await import(`${module_path}/ai_module/index.mjs`);
196
196
 
197
197
  if (account_obj.account_info?.profile_picture) {
198
- if (!account_obj.account_info?.profile_avatar) {
199
- set_account_profile_picture(uid, uid, {}, job_id, headers);
198
+ if (!account_obj.account_info?.profile_avatar && account_obj.profile_avatar_stat !== 2) {
199
+ debugger;
200
+ set_account_profile_picture(uid, uid, account_obj.account_info, job_id, headers);
200
201
  }
201
202
  }
202
203
  // if (account_obj.account_info?.profile_picture) {
@@ -2113,7 +2114,7 @@ const set_account_profile_picture = async function (uid, account_uid, metadata,
2113
2114
 
2114
2115
  let { code: account_code, data: account_obj2 } = await db_module.get_couch_doc('xuda_accounts', account_uid);
2115
2116
  account_obj = account_obj2;
2116
- let account_info = account_obj.account_info;
2117
+ account_info = account_obj.account_info;
2117
2118
 
2118
2119
  account_info.profile_picture_obj = file_ret.data;
2119
2120
 
@@ -2164,7 +2165,7 @@ const set_account_profile_picture = async function (uid, account_uid, metadata,
2164
2165
 
2165
2166
  let { code: account_code, data: account_obj3 } = await db_module.get_couch_doc('xuda_accounts', account_uid);
2166
2167
  account_obj = account_obj3;
2167
- let account_info = account_obj.account_info;
2168
+ account_info = account_obj.account_info;
2168
2169
 
2169
2170
  account_info.profile_avatar_obj = file_ret;
2170
2171
  account_info.profile_avatar = account_info.profile_avatar_obj.file_url;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.1463",
3
+ "version": "1.2.1465",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {