@xuda.io/account_module 1.2.1759 → 1.2.1760

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 +8 -1
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -1141,7 +1141,7 @@ const get_contact_pattern = async function (doc) {
1141
1141
  let ret = `default-pattern.png`;
1142
1142
  debugger;
1143
1143
  if (doc.account_type === 'business') {
1144
- if (doc?.account_type_info?.is_real_person && doc?.person_info?.person_full_name !== 'Not available') {
1144
+ if (doc?.is_real_person) {
1145
1145
  ret = doc.profile_picture;
1146
1146
  }
1147
1147
  } else {
@@ -1380,8 +1380,15 @@ export const get_contact_info = async function (uid, contact_doc, _id) {
1380
1380
  doc.email = doc.email;
1381
1381
  }
1382
1382
 
1383
+ account_type_info;
1384
+
1385
+ doc.is_real_person = doc.account_type_info.is_real_person && doc?.person_info?.person_full_name !== 'Not available';
1383
1386
  doc.icon_pattern = await get_contact_pattern(doc);
1384
1387
 
1388
+ delete doc.account_type_info;
1389
+ delete doc.person_info;
1390
+ delete doc.business_info;
1391
+
1385
1392
  const contact_chat_conversation_count_ret = await chat_conversation_count();
1386
1393
  const contact_chat_conversation_read_ret = await chat_conversation_read();
1387
1394
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.1759",
3
+ "version": "1.2.1760",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {