@context-engine-bridge/context-engine-mcp-bridge 0.0.68 → 0.0.69
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/package.json +1 -1
- package/src/mcpServer.js +5 -11
package/package.json
CHANGED
package/src/mcpServer.js
CHANGED
|
@@ -1945,17 +1945,11 @@ function _mergeResults(primaryText, additionalTexts) {
|
|
|
1945
1945
|
if (Array.isArray(resultsArr) && resultsArr.length > 1) {
|
|
1946
1946
|
resultsArr.sort((a, b) => (b.score || 0) - (a.score || 0));
|
|
1947
1947
|
}
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
pInner.results_json = sliced;
|
|
1954
|
-
} else {
|
|
1955
|
-
pInner.results = sliced;
|
|
1956
|
-
}
|
|
1957
|
-
if (typeof pInner.total === "number") pInner.total = sliced.length;
|
|
1958
|
-
if (typeof pInner.count === "number") pInner.count = sliced.length;
|
|
1948
|
+
if (typeof pInner.total === "number" && Array.isArray(resultsArr)) {
|
|
1949
|
+
pInner.total = resultsArr.length;
|
|
1950
|
+
}
|
|
1951
|
+
if (typeof pInner.count === "number" && Array.isArray(resultsArr)) {
|
|
1952
|
+
pInner.count = resultsArr.length;
|
|
1959
1953
|
}
|
|
1960
1954
|
|
|
1961
1955
|
primary._cross_collection = true;
|