@xuda.io/account_module 1.2.1060 → 1.2.1061
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.
- package/index.mjs +26 -26
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -2654,33 +2654,33 @@ export const unarchive_account_profile = async function (req) {
|
|
|
2654
2654
|
}
|
|
2655
2655
|
};
|
|
2656
2656
|
|
|
2657
|
-
export const unfriend_account_profile = async function (req) {
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2657
|
+
// export const unfriend_account_profile = async function (req) {
|
|
2658
|
+
// const { profile_id } = req;
|
|
2659
|
+
// try {
|
|
2660
|
+
// const contact_ret = await db_module.get_couch_doc('xuda_accounts', profile_id);
|
|
2661
|
+
// if (contact_ret.code < 0) {
|
|
2662
|
+
// throw new Error(contact_ret.data);
|
|
2663
|
+
// }
|
|
2664
|
+
// var account_profile_doc = contact_ret.data;
|
|
2665
2665
|
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
|
|
2672
|
-
|
|
2666
|
+
// if (!account_profile_doc.team_req_id) {
|
|
2667
|
+
// throw new Error('no friend relationship found');
|
|
2668
|
+
// }
|
|
2669
|
+
// let req_doc = await db_module.get_couch_doc_native('xuda_team', account_profile_doc.team_req_id);
|
|
2670
|
+
// req_doc.team_req_stat = 4;
|
|
2671
|
+
// req_doc.team_req_stat_desc = 'unfriend by the user';
|
|
2672
|
+
// await db_module.get_couch_doc_native('xuda_team', account_profile_doc.team_req_id);
|
|
2673
2673
|
|
|
2674
|
-
|
|
2675
|
-
|
|
2674
|
+
// account_profile_doc.team_req_id = null;
|
|
2675
|
+
// const account_profile_save_ret = await db_module.save_couch_doc('xuda_accounts', account_profile_doc);
|
|
2676
2676
|
|
|
2677
|
-
|
|
2677
|
+
// const req_save_ret = await db_module.save_couch_doc('xuda_team', req_doc);
|
|
2678
2678
|
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
};
|
|
2679
|
+
// return req_save_ret;
|
|
2680
|
+
// } catch (err) {
|
|
2681
|
+
// return {
|
|
2682
|
+
// code: -21,
|
|
2683
|
+
// data: err.message,
|
|
2684
|
+
// };
|
|
2685
|
+
// }
|
|
2686
|
+
// };
|