1
0
mirror of synced 2025-02-22 15:13:13 +03:00

dispatch the event after the snapshot was taken

This commit is contained in:
Daniel Freudenberger 2011-10-23 01:27:09 +02:00
parent 5e28273548
commit fa8000fa5c

View File

@ -329,16 +329,16 @@ class UnitOfWork implements PropertyChangedListener
throw $e; throw $e;
} }
// Raise postFlush
if ($this->evm->hasListeners(Events::postFlush)) {
$this->evm->dispatchEvent(Events::postFlush, new Event\PostFlushEventArgs($this->em));
}
// Take new snapshots from visited collections // Take new snapshots from visited collections
foreach ($this->visitedCollections as $coll) { foreach ($this->visitedCollections as $coll) {
$coll->takeSnapshot(); $coll->takeSnapshot();
} }
// Raise postFlush
if ($this->evm->hasListeners(Events::postFlush)) {
$this->evm->dispatchEvent(Events::postFlush, new Event\PostFlushEventArgs($this->em));
}
// Clear up // Clear up
$this->entityInsertions = $this->entityInsertions =
$this->entityUpdates = $this->entityUpdates =