Skip to content
Snippets Groups Projects
Commit 9bea4a70 authored by Daniel Gerhardt's avatar Daniel Gerhardt
Browse files

Publish AfterPatchEvents for bulk patching

The event is now published for every single patched entity.
parent 452cc241
Branches
No related merge requests found
......@@ -206,7 +206,10 @@ public class DefaultEntityServiceImpl<T extends Entity> implements EntityService
}
Iterable<T> patchedEntities = repository.saveAll(entities);
patchedEntities.forEach(this::modifyRetrieved);
patchedEntities.forEach((e) -> {
eventPublisher.publishEvent(new AfterPatchEvent<>(this, e, propertyGetter, changes));
modifyRetrieved(e);
});
return patchedEntities;
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment