diff --git a/src/main/java/it/finanze/sanita/fse2/ms/iniclient/service/impl/IniInvocationSRV.java b/src/main/java/it/finanze/sanita/fse2/ms/iniclient/service/impl/IniInvocationSRV.java index 7cb83939..e5add645 100644 --- a/src/main/java/it/finanze/sanita/fse2/ms/iniclient/service/impl/IniInvocationSRV.java +++ b/src/main/java/it/finanze/sanita/fse2/ms/iniclient/service/impl/IniInvocationSRV.java @@ -331,6 +331,11 @@ public GetReferenceResponseDTO getReference(final String oid, final JWTTokenDTO workflowInstanceId,startingDate); StringBuilder sb = buildReferenceResponse(response); + if(response.getTotalResultCount().intValue()==0) { + out.setErrorMessage("No record found"); + return out; + } + if(!StringUtility.isNullOrEmpty(sb.toString())){ out.setErrorMessage(sb.toString()); } else {