The expression return $generator->gener...this->reference, false) could return the type false which is incompatible with the type-hinted return string. Consider adding an additional type-check to rule them out.
Loading history...
43
}
44
45
public static function loadValidatorMetadata(ClassMetadata $metadata): void
46
{
47
$metadata->addPropertyConstraints('reference', [
48
new Assert\Regex([
49
'pattern' => '/^[a-zA-Z0-9]*$/',
50
'match' => true
51
]),
52
new Assert\Length([
53
'min' => 1,
54
'max' => 21 // 25 minus 'RF' prefix minus 2-digit check sum