@xuda.io/ai_module 1.1.3936 → 1.1.3938
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 +3 -2
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -2809,8 +2809,9 @@ export const get_apps = async function (req, job_id, headers) {
|
|
|
2809
2809
|
|
|
2810
2810
|
let user_apps = { docs: [], total_docs: 0 };
|
|
2811
2811
|
if (filter_type !== 'pending') {
|
|
2812
|
+
user_apps = await db_module.find_app_couch_query(app_id, opt);
|
|
2812
2813
|
if (!limit || mini_app_id) {
|
|
2813
|
-
user_apps =
|
|
2814
|
+
user_apps.total_docs = user_apps.docs.length;
|
|
2814
2815
|
} else {
|
|
2815
2816
|
delete opt.sort;
|
|
2816
2817
|
delete opt.skip;
|
|
@@ -2866,7 +2867,7 @@ export const get_apps = async function (req, job_id, headers) {
|
|
|
2866
2867
|
docs.push(doc);
|
|
2867
2868
|
}
|
|
2868
2869
|
|
|
2869
|
-
return { code: 2, data: { docs: [...requests_from.docs, ...docs], total_docs: user_apps.total_docs + requests_from.total_docs
|
|
2870
|
+
return { code: 2, data: { docs: [...requests_from.docs, ...docs], total_docs: user_apps.total_docs + requests_from.total_docs } };
|
|
2870
2871
|
} catch (err) {
|
|
2871
2872
|
return { code: -11, data: err.message };
|
|
2872
2873
|
}
|