This is an automated email from the ASF dual-hosted git repository.
aradzinski pushed a commit to branch NLPCRAFT-278
in repository https://gitbox.apache.org/repos/asf/incubator-nlpcraft.git
The following commit(s) were added to refs/heads/NLPCRAFT-278 by this push:
new 8e2872c WIP.
8e2872c is described below
commit 8e2872c189364d9ac30c1b55cf71473c54b9dab9
Author: Aaron Radzinski <[email protected]>
AuthorDate: Tue Mar 23 14:32:29 2021 -0700
WIP.
---
.../org/apache/nlpcraft/model/intent/compiler/NCIdlCompilerBase.scala | 2 +-
.../model/intent/idl/compiler/functions/NCIdlFunctionsOther.scala | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git
a/nlpcraft/src/main/scala/org/apache/nlpcraft/model/intent/compiler/NCIdlCompilerBase.scala
b/nlpcraft/src/main/scala/org/apache/nlpcraft/model/intent/compiler/NCIdlCompilerBase.scala
index b0b83d7..96b3785 100644
---
a/nlpcraft/src/main/scala/org/apache/nlpcraft/model/intent/compiler/NCIdlCompilerBase.scala
+++
b/nlpcraft/src/main/scala/org/apache/nlpcraft/model/intent/compiler/NCIdlCompilerBase.scala
@@ -620,7 +620,7 @@ trait NCIdlCompilerBase {
try
if (lst.isEmpty)
throw newRuntimeError(s"Unexpected empty list in IDL
function '$fun()'.")
- else
+ else
Z(Collections.min(lst, null), n)
catch {
case e: Exception ⇒ throw rtListTypeError(fun, e)
diff --git
a/nlpcraft/src/test/scala/org/apache/nlpcraft/model/intent/idl/compiler/functions/NCIdlFunctionsOther.scala
b/nlpcraft/src/test/scala/org/apache/nlpcraft/model/intent/idl/compiler/functions/NCIdlFunctionsOther.scala
index 7e3f80e..7f62862 100644
---
a/nlpcraft/src/test/scala/org/apache/nlpcraft/model/intent/idl/compiler/functions/NCIdlFunctionsOther.scala
+++
b/nlpcraft/src/test/scala/org/apache/nlpcraft/model/intent/idl/compiler/functions/NCIdlFunctionsOther.scala
@@ -43,8 +43,8 @@ class NCIdlFunctionsOther extends NCIdlFunctions {
// JSON.
test(
- s"has(json('$js'), 'k1') == true",
- s"has(json('$js'), 'k2') == false"
+ s"has(keys(json('$js')), 'k1') == true",
+ s"has(keys(json('$js')), 'k2') == false"
)
}
}