@@ -446,7 +446,7 @@ protected async Task<IActionResult> InternalUpdate(string prefix, string id, Rep
446446 if ( ! _options . IsFullRepresentationReturned )
447447 {
448448 var content = representation . ToResponse ( location , true , mergeExtensionAttributes : _options . MergeExtensionAttributes ) ;
449- if ( IsPublishEvtsEnabled ) await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty ) ) ;
449+ if ( IsPublishEvtsEnabled ) await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty , updateResult . Result . PatchOperations ) ) ;
450450 return BuildHTTPResult ( HttpStatusCode . OK , location , representation . Version , content ) ;
451451 }
452452 else
@@ -455,7 +455,7 @@ protected async Task<IActionResult> InternalUpdate(string prefix, string id, Rep
455455 representation = getRepresentationResult . Result ;
456456 await _attributeReferenceEnricher . Enrich ( _resourceType , new List < SCIMRepresentation > { representation } , _uriProvider . GetAbsoluteUriWithVirtualPath ( ) ) ;
457457 var content = representation . ToResponse ( location , true , mergeExtensionAttributes : _options . MergeExtensionAttributes ) ;
458- if ( IsPublishEvtsEnabled ) await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty ) ) ;
458+ if ( IsPublishEvtsEnabled ) await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty , updateResult . Result . PatchOperations ) ) ;
459459 return BuildHTTPResult ( HttpStatusCode . OK , location , representation . Version , content ) ;
460460 }
461461 }
@@ -520,7 +520,7 @@ protected async Task<IActionResult> InternalPatch(string prefix, string id, Patc
520520 {
521521 var content = representation . ToResponse ( location , true , mergeExtensionAttributes : _options . MergeExtensionAttributes ) ;
522522 if ( IsPublishEvtsEnabled )
523- await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty ) ) ;
523+ await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty , patchRes . Result . PatchOperations ) ) ;
524524
525525 return BuildHTTPResult ( HttpStatusCode . OK , location , representation . Version , content ) ;
526526 }
@@ -530,7 +530,7 @@ protected async Task<IActionResult> InternalPatch(string prefix, string id, Patc
530530 representation = getRepresentationResult . Result ;
531531 await _attributeReferenceEnricher . Enrich ( _resourceType , new List < SCIMRepresentation > { representation } , _uriProvider . GetAbsoluteUriWithVirtualPath ( ) ) ;
532532 var content = representation . ToResponse ( location , true , mergeExtensionAttributes : _options . MergeExtensionAttributes ) ;
533- if ( IsPublishEvtsEnabled ) await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty ) ) ;
533+ if ( IsPublishEvtsEnabled ) await _busControl . Publish ( new RepresentationUpdatedEvent ( representation . Id , representation . Version , GetResourceType ( _resourceType ) , content , _options . IncludeToken ? Request . GetToken ( ) : string . Empty , patchRes . Result . PatchOperations ) ) ;
534534 return BuildHTTPResult ( HttpStatusCode . OK , location , representation . Version , content ) ;
535535 }
536536 }
0 commit comments