@xuda.io/account_module 1.2.2045 → 1.2.2046

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 -9
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -2635,8 +2635,6 @@ export const unpin_contact = async function (req) {
2635
2635
  };
2636
2636
 
2637
2637
  export const not_spam_contact = async function (req, job_id, headers) {
2638
- const email_module = await import(`${module_path}/email_module/index.mjs`);
2639
-
2640
2638
  const { contact_id, uid } = req;
2641
2639
  const account_profile_info = await get_active_account_profile_info(uid);
2642
2640
  try {
@@ -2696,7 +2694,7 @@ export const not_spam_contact = async function (req, job_id, headers) {
2696
2694
  // summarized_body
2697
2695
  req.uid = email.uid;
2698
2696
  req.email_id = email._id;
2699
- await email_module.process_pending_email(req, job_id, headers);
2697
+ await email_ms.process_pending_email(req, job_id, headers);
2700
2698
  }
2701
2699
 
2702
2700
  return contact_save_ret;
@@ -3484,22 +3482,18 @@ export const archive_expire_ai_credits = async function () {
3484
3482
  };
3485
3483
 
3486
3484
  export const read_accounts_emails = async function () {
3487
- const email_module = await import(`${module_path}/email_module/index.mjs`);
3488
-
3489
3485
  const active_accounts = await db_module.find_couch_query('xuda_accounts', { selector: { stat: 3, docType: 'account' }, limit: 99999 });
3490
3486
  for await (let account_doc of active_accounts.docs) {
3491
3487
  if (!account_doc?.account_info?.active_account_profile_id) continue;
3492
- email_module.refresh_mailboxes({ uid: account_doc._id });
3488
+ email_ms.refresh_mailboxes({ uid: account_doc._id });
3493
3489
  }
3494
3490
  };
3495
3491
 
3496
3492
  export const process_accounts_emails = async function () {
3497
- const email_module = await import(`${module_path}/email_module/index.mjs`);
3498
-
3499
3493
  const active_accounts = await db_module.find_couch_query('xuda_accounts', { selector: { stat: 3, docType: 'account' }, limit: 99999 });
3500
3494
  for await (let account_doc of active_accounts.docs) {
3501
3495
  if (!account_doc?.account_info?.active_account_profile_id) continue;
3502
- email_module.process_emails({ uid: account_doc._id });
3496
+ email_ms.process_emails({ uid: account_doc._id });
3503
3497
  }
3504
3498
  };
3505
3499
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/account_module",
3
- "version": "1.2.2045",
3
+ "version": "1.2.2046",
4
4
  "description": "Xuda Account Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {