Skip to content

Commit feb165e

Browse files
authored
[Validator] Use import instead of FQCN
1 parent e082c3a commit feb165e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

reference/constraints/Type.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,12 @@ This will check if ``id`` is an instance of ``Ramsey\Uuid\UuidInterface``,
6464
// src/Entity/Author.php
6565
namespace App\Entity;
6666
67+
use Ramsey\Uuid\UuidInterface;
6768
use Symfony\Component\Validator\Constraints as Assert;
6869
6970
class Author
7071
{
71-
#[Assert\Type('Ramsey\Uuid\UuidInterface')]
72+
#[Assert\Type(UuidInterface::class)]
7273
protected $id;
7374
7475
#[Assert\Type('string')]

0 commit comments

Comments
 (0)