DATACMNS-1122 - Improve message for absent required property in PersistentEntity.getRequiredPersistentProperty(…).

Exception message now contains the property name.
This commit is contained in:
Mark Paluch
2017-07-21 08:54:39 +02:00
parent 013bda0dd2
commit 86945f81d1
2 changed files with 11 additions and 1 deletions

View File

@@ -151,7 +151,7 @@ public interface PersistentEntity<T, P extends PersistentProperty<P>> extends It
return property;
}
throw new IllegalStateException(String.format("Required identifier property not found for %s!", getType()));
throw new IllegalStateException(String.format("Required property %s not found for %s!", name, getType()));
}
/**