Mercurial > hg > orthanc
diff OrthancServer/Sources/OrthancRestApi/OrthancRestAnonymizeModify.cpp @ 4796:94616af363ec filter-store-instance
added ReceivedCStoreInstanceFilter lua callback + OrthancPluginRegisterIncomingCStoreInstanceFilter in sdk
author | Alain Mazy <am@osimis.io> |
---|---|
date | Fri, 01 Oct 2021 18:36:45 +0200 |
parents | 388d108f6e4b |
children | 70d2a97ca8cb 7053502fbf97 |
line wrap: on
line diff
--- a/OrthancServer/Sources/OrthancRestApi/OrthancRestAnonymizeModify.cpp Thu Sep 30 17:52:07 2021 +0200 +++ b/OrthancServer/Sources/OrthancRestApi/OrthancRestAnonymizeModify.cpp Fri Oct 01 18:36:45 2021 +0200 @@ -554,16 +554,16 @@ toStore->SetOrigin(DicomInstanceOrigin::FromRest(call)); ServerContext& context = OrthancRestApi::GetContext(call); - StoreStatus status = context.Store(id, *toStore, StoreInstanceMode_Default); + ServerContext::StoreResult result = context.Store(id, *toStore, StoreInstanceMode_Default); - if (status == StoreStatus_Failure) + if (result.GetStatus() == StoreStatus_Failure) { throw OrthancException(ErrorCode_CannotStoreInstance); } if (sendAnswer) { - OrthancRestApi::GetApi(call).AnswerStoredInstance(call, *toStore, status, id); + OrthancRestApi::GetApi(call).AnswerStoredInstance(call, *toStore, result.GetStatus(), id); } }