-
-
Save mishanon/f29e893053e5cdd36871c3808248e10a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
arrayOfElementsOrElementApplyMethod($value, function($value, $validator, $logFiltered) { | |
if ($validator->isValid($value) === false) { | |
if ($logFiltered) { | |
// create a log item | |
$logItem = new ProductFilteredItem($testObject->getAggregateRoot()); | |
$logItem->setActorId($actorId); | |
$logItem->setProductContainerId($testObject->getProductId()); | |
$logItem->setAddedOn(new \Core\Domain\LendoDateTime()); | |
$logItem->setFilterId($validator->getFilterId()); | |
$logItem->setFilteredValue((string)$value); | |
$testObject->getProductFilteredLog()->addItem($logItem); | |
return false; | |
} | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment