do not check for missing correspondingremotemessageuri
@@ -193,9 +193,12 @@ public class AgreementProtocolState {
messages.stream().forEach(message -> {
if (message.getCorrespondingRemoteMessageURI() != null && ! message.getCorrespondingRemoteMessageURI().equals(message.getMessageURI())) {
ConversationMessage other = messagesByURI.get(message.getCorrespondingRemoteMessageURI());
- throwExceptionIfOtherisMissing(message.getMessageURI(), message.getCorrespondingRemoteMessageURI(), other, "msg:hasCorrespondingRemoteMessage");
+ if (other == null){
+ message.setCorrespondingRemoteMessageURI(null);
+ } else {
message.setCorrespondingRemoteMessageRef(other);
other.setCorrespondingRemoteMessageRef(message);
+ }
}
message.getPrevious().stream().filter(uri -> !uri.equals(message.getMessageURI()))
.forEach(uri -> {
