@xuda.io/account_module 1.2.499 → 1.2.501

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 +35 -34
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -1355,40 +1355,41 @@ export const get_contacts = async function (req) {
1355
1355
  const contacts = await db_module.find_couch_query('xuda_contacts', opt);
1356
1356
 
1357
1357
  for await (let doc of contacts.docs) {
1358
- if (doc.contact_uid) {
1359
- const account_info_ret = await get_account_name({ uid_query: doc.contact_uid });
1360
- if (account_info_ret.code < 0) {
1361
- continue; // throw new Error(`account ${contact_uid} not found`);
1362
- }
1363
-
1364
- doc.profile_avatar = account_info_ret.data.profile_avatar;
1365
-
1366
- doc.card_background = get_contact_background(doc);
1367
-
1368
- //membership_plan
1369
- doc.name = `${account_info_ret.data.first_name} ${account_info_ret.data.last_name}`;
1370
-
1371
- doc.telephone = account_info_ret.data.phone;
1372
-
1373
- // doc.notifications = 45;
1374
- // doc.online = true;
1375
- if (doc.team_req_id) {
1376
- try {
1377
- const req_doc = await db_module.get_couch_doc_native('xuda_team', doc.team_req_id);
1378
- doc.connection_stat = req_doc.team_req_stat;
1379
- } catch (error) {
1380
- doc.connection_stat = 0;
1381
- }
1382
- }
1383
-
1384
- doc.icon_pattern = get_contact_pattern(doc);
1385
- }
1386
- doc.border = get_contact_border(doc);
1387
- if (!doc.name) {
1388
- doc.name = doc.email;
1389
- }
1390
-
1391
- doc.email = '';
1358
+ // if (doc.contact_uid) {
1359
+ // const account_info_ret = await get_account_name({ uid_query: doc.contact_uid });
1360
+ // if (account_info_ret.code < 0) {
1361
+ // continue; // throw new Error(`account ${contact_uid} not found`);
1362
+ // }
1363
+
1364
+ // doc.profile_avatar = account_info_ret.data.profile_avatar;
1365
+
1366
+ // doc.card_background = get_contact_background(doc);
1367
+
1368
+ // //membership_plan
1369
+ // doc.name = `${account_info_ret.data.first_name} ${account_info_ret.data.last_name}`;
1370
+
1371
+ // doc.telephone = account_info_ret.data.phone;
1372
+
1373
+ // // doc.notifications = 45;
1374
+ // // doc.online = true;
1375
+ // if (doc.team_req_id) {
1376
+ // try {
1377
+ // const req_doc = await db_module.get_couch_doc_native('xuda_team', doc.team_req_id);
1378
+ // doc.connection_stat = req_doc.team_req_stat;
1379
+ // } catch (error) {
1380
+ // doc.connection_stat = 0;
1381
+ // }
1382
+ // }
1383
+
1384
+ // doc.icon_pattern = get_contact_pattern(doc);
1385
+ // }
1386
+ // doc.border = get_contact_border(doc);
1387
+ // if (!doc.name) {
1388
+ // doc.name = doc.email;
1389
+ // }
1390
+
1391
+ // doc.email = '';
1392
+ doc = await get_contact_info(doc);
1392
1393
  }
1393
1394
 
1394
1395
  let requests_to = { docs: [] };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.499",
3
+ "version": "1.2.501",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {