Total Complexity | 1 |
Total Lines | 6 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
5 | class UnitOfWorkException extends StorageException |
||
6 | { |
||
7 | public static function forPersistingEntityInInvalidState($entity): UnitOfWorkException |
||
8 | { |
||
9 | $entity = get_class($entity); |
||
10 | return new self("Cannot persist entity {$entity} which is in detached or removed state"); |
||
11 | } |
||
13 |