Skip to content

Commit 5b4961f

Browse files
committed
[DoctrineBridge] Fix exception message
1 parent 100b188 commit 5b4961f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Symfony/Bridge/Doctrine/Form/ChoiceList/DoctrineChoiceLoader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function __construct(ObjectManager $manager, string $class, IdReader $idR
4040
$classMetadata = $manager->getClassMetadata($class);
4141

4242
if ($idReader && !$idReader->isSingleId()) {
43-
throw new \InvalidArgumentException(sprintf('The second argument `$idReader` of "%s" must be null when the query cannot be optimized because of composite id fields.', __METHOD__));
43+
throw new \InvalidArgumentException(sprintf('The `$idReader` argument of "%s" must be null when the query cannot be optimized because of composite id fields.', __METHOD__));
4444
}
4545

4646
$this->manager = $manager;

src/Symfony/Bridge/Doctrine/Tests/Form/ChoiceList/DoctrineChoiceLoaderTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ public function testLoadChoicesForValuesLoadsOnlyChoicesIfValueIsIdReader()
426426
public function testPassingIdReaderWithoutSingleIdEntity()
427427
{
428428
$this->expectException(\InvalidArgumentException::class);
429-
$this->expectExceptionMessage('The second argument `$idReader` of "Symfony\\Bridge\\Doctrine\\Form\\ChoiceList\\DoctrineChoiceLoader::__construct" must be null when the query cannot be optimized because of composite id fields.');
429+
$this->expectExceptionMessage('The `$idReader` argument of "Symfony\\Bridge\\Doctrine\\Form\\ChoiceList\\DoctrineChoiceLoader::__construct" must be null when the query cannot be optimized because of composite id fields.');
430430

431431
$idReader = $this->createMock(IdReader::class);
432432
$idReader->expects($this->once())

0 commit comments

Comments
 (0)