| Conditions | 4 |
| Paths | 3 |
| Total Lines | 14 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 2 |
| 1 | <?php |
||
| 14 | { |
||
| 15 | $entityManager = $onFlushEventArgs->getEntityManager(); |
||
| 16 | $unitOfWork = $entityManager->getUnitOfWork(); |
||
| 17 | |||
| 18 | $entities = array_merge( |
||
| 19 | $unitOfWork->getScheduledEntityInsertions(), |
||
| 20 | $unitOfWork->getScheduledEntityUpdates() |
||
| 21 | ); |
||
| 22 | |||
| 23 | foreach ($entities as $entity) { |
||
| 24 | if (!$entity instanceof CustomerInterface) { |
||
| 25 | continue; |
||
| 26 | } |
||
| 27 | |||
| 28 | $user = $entity->getUser(); |
||
| 40 |