Simple fixes (#976)

* Should be only the really simple stuff.
* Final cleanups.
This commit is contained in:
Koen De Groote
2017-02-23 23:46:51 +13:00
committed by Rob Bygrave
parent 8bb884374b
commit 6120a465e1
59 changed files with 111 additions and 125 deletions
@@ -8,6 +8,7 @@ import io.ebeaninternal.api.SpiExpressionRequest;
import io.ebeaninternal.server.el.ElPropertyValue;
import java.io.IOException;
import java.util.Arrays;
public class SimpleExpression extends AbstractValueExpression {
@@ -36,7 +37,7 @@ public class SimpleExpression extends AbstractValueExpression {
String idName = prop.getAssocIdExpression(propName, "");
Object[] ids = prop.getAssocIdValues((EntityBean) value());
if (ids == null || ids.length != 1) {
throw new IllegalArgumentException("Expecting 1 Id value for " + idName + " but got " + ids);
throw new IllegalArgumentException("Expecting 1 Id value for " + idName + " but got " + Arrays.toString(ids));
}
context.writeSimple(type, idName, ids[0]);
} else {