wingbot 3.27.0-alpha.2 → 3.27.0-alpha.3
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
CHANGED
|
@@ -539,19 +539,15 @@ class CustomEntityDetectionModel {
|
|
|
539
539
|
|
|
540
540
|
if (typeof extractValue === 'function') {
|
|
541
541
|
value = extractValue(match, useEntities);
|
|
542
|
-
} else if (typeof extractValue === 'string' || dependencies.length
|
|
542
|
+
} else if (typeof extractValue === 'string' || dependencies.length > 0) {
|
|
543
543
|
const entityName = typeof extractValue === 'string'
|
|
544
544
|
? extractValue
|
|
545
545
|
: dependencies[0];
|
|
546
546
|
|
|
547
547
|
const entity = this._entityByDependency(useEntities, entityName);
|
|
548
548
|
value = entity ? entity.value : null;
|
|
549
|
-
} else if (entities.length === 0) {
|
|
550
|
-
[value] = match;
|
|
551
549
|
} else {
|
|
552
|
-
value =
|
|
553
|
-
[e.entity]: e.value
|
|
554
|
-
}), {});
|
|
550
|
+
[value] = match;
|
|
555
551
|
}
|
|
556
552
|
|
|
557
553
|
return {
|