@xuda.io/account_module 1.2.1359 → 1.2.1361

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 +3 -3
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -1858,7 +1858,7 @@ export const onboarding_completed = async function (req, job_id, headers) {
1858
1858
  }
1859
1859
  };
1860
1860
 
1861
- export const ts_contact = async function (contact_id) {
1861
+ export const ts_contact = async function (uid, contact_id) {
1862
1862
  try {
1863
1863
  const contact_doc = await get_contact(uid, contact_id);
1864
1864
  contact_doc.ts = Date.now();
@@ -1966,7 +1966,7 @@ export const add_contact = async function (req, job_id, headers) {
1966
1966
  limit: 1,
1967
1967
  fields: ['_id'],
1968
1968
  };
1969
- const user_contacts = await find_app_contact_query(account_profile_info.app_id, opt);
1969
+ const user_contacts = await find_contact_query(uid, opt);
1970
1970
  if (user_contacts.docs.length) {
1971
1971
  // throw new Error('contact already exist');
1972
1972
  return { code: -1, data: 'contact already exist', contact_id: user_contacts.docs[0]._id };
@@ -2007,7 +2007,7 @@ export const add_contact = async function (req, job_id, headers) {
2007
2007
  _id: await _common.xuda_get_uuid('contact'),
2008
2008
  email,
2009
2009
  name,
2010
- stat: stat || 1,
2010
+ stat: stat || 3,
2011
2011
  date_created: d,
2012
2012
  ts: d,
2013
2013
  docType: 'contact',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.1359",
3
+ "version": "1.2.1361",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {