mirror of
https://github.com/apache/olingo-odata4.git
synced 2025-02-15 22:46:17 +00:00
OLINGO-1112: checking the key values for null when building the location URL in the response
This commit is contained in:
parent
c85b6a6239
commit
004515aaee
@ -215,6 +215,10 @@ public class EntityResponse extends ServiceResponse {
|
||||
String propertyType = entity.getProperty(key).getType();
|
||||
Object propertyValue = entity.getProperty(key).getValue();
|
||||
|
||||
if (propertyValue == null) {
|
||||
throw new EdmPrimitiveTypeException("The key value for property "+key+" is invalid; Key value cannot be null");
|
||||
}
|
||||
|
||||
if(propertyType.startsWith("Edm.")) {
|
||||
propertyType = propertyType.substring(4);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user