@xuda.io/ai_module 1.1.5145 → 1.1.5146
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 +4 -2
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -10976,8 +10976,10 @@ export const get_chat_suggestions = async function (uid, ai_agents, conversation
|
|
|
10976
10976
|
};
|
|
10977
10977
|
|
|
10978
10978
|
const agents_docs = await get_agents();
|
|
10979
|
-
|
|
10980
|
-
|
|
10979
|
+
let suggestions = [];
|
|
10980
|
+
if (agents_docs.length) {
|
|
10981
|
+
suggestions = await get_suggestions();
|
|
10982
|
+
}
|
|
10981
10983
|
return { code: 44, data: suggestions };
|
|
10982
10984
|
} catch (err) {
|
|
10983
10985
|
return { code: -44, data: err.message || String(err) };
|