@backstage/plugin-search-backend-node
Advanced tools
Comparing version 0.0.0-nightly-202192122645 to 0.0.0-nightly-202192322437
# @backstage/plugin-search-backend-node | ||
## 0.0.0-nightly-202192322437 | ||
### Patch Changes | ||
- a369f19e7e: Handle special case when filter array has single value optimizing Lunr search behaviour. | ||
- Updated dependencies | ||
- @backstage/search-common@0.0.0-nightly-202192322437 | ||
## 0.4.2 | ||
@@ -4,0 +12,0 @@ |
@@ -156,6 +156,7 @@ 'use strict'; | ||
if (filters) { | ||
Object.entries(filters).forEach(([field, value]) => { | ||
Object.entries(filters).forEach(([field, fieldValue]) => { | ||
if (!q.allFields.includes(field)) { | ||
throw new Error(`unrecognised field ${field}`); | ||
} | ||
const value = Array.isArray(fieldValue) && fieldValue.length === 1 ? fieldValue[0] : fieldValue; | ||
if (["string", "number", "boolean"].includes(typeof value)) { | ||
@@ -162,0 +163,0 @@ q.term(lunr__default['default'].tokenizer(value == null ? void 0 : value.toString()), { |
{ | ||
"name": "@backstage/plugin-search-backend-node", | ||
"description": "A library for Backstage backend plugins that want to interact with the search backend plugin", | ||
"version": "0.0.0-nightly-202192122645", | ||
"version": "0.0.0-nightly-202192322437", | ||
"main": "dist/index.cjs.js", | ||
@@ -23,3 +23,3 @@ "types": "dist/index.d.ts", | ||
"dependencies": { | ||
"@backstage/search-common": "^0.0.0-nightly-202192122645", | ||
"@backstage/search-common": "^0.0.0-nightly-202192322437", | ||
"winston": "^3.2.1", | ||
@@ -30,4 +30,4 @@ "lunr": "^2.3.9", | ||
"devDependencies": { | ||
"@backstage/backend-common": "^0.0.0-nightly-202192122645", | ||
"@backstage/cli": "^0.0.0-nightly-202192122645" | ||
"@backstage/backend-common": "^0.0.0-nightly-202192322437", | ||
"@backstage/cli": "^0.0.0-nightly-202192322437" | ||
}, | ||
@@ -34,0 +34,0 @@ "files": [ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
42882
345