Skip to content

Commit 9b78591

Browse files
committed
mark getRequiredOptions()/getDefaultOption() of UniqueEntity as deprecated
1 parent 36d8d5d commit 9b78591

File tree

4 files changed

+20
-0
lines changed

4 files changed

+20
-0
lines changed

UPGRADE-7.4.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@ DependencyInjection
2323

2424
* Add argument `$target` to `ContainerBuilder::registerAliasForArgument()`
2525

26+
DoctrineBridge
27+
--------------
28+
29+
* Deprecate `UniqueEntity::getRequiredOptions()` and `UniqueEntity::getDefaultOption()`
30+
2631
FrameworkBundle
2732
---------------
2833

@@ -48,6 +53,8 @@ Security
4853
Validator
4954
---------
5055

56+
* Deprecate `getRequiredOptions()` and `getDefaultOption()` methods of the `All`, `AtLeastOneOf`, `CardScheme`, `Collection`,
57+
`CssColor`, `Expression`, `Regex`, `Sequentially`, `Type`, and `When` constraints
5158
* Deprecate evaluating options in the base `Constraint` class. Initialize properties in the constructor of the concrete constraint
5259
class instead.
5360

src/Symfony/Bridge/Doctrine/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
CHANGELOG
22
=========
33

4+
7.4
5+
---
6+
7+
* Deprecate `UniqueEntity::getRequiredOptions()` and `UniqueEntity::getDefaultOption()`
8+
49
7.3
510
---
611

src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntity.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,9 @@ public function __construct(
9191
$this->identifierFieldNames = $identifierFieldNames ?? $this->identifierFieldNames;
9292
}
9393

94+
/**
95+
* @deprecated since Symfony 7.4
96+
*/
9497
public function getRequiredOptions(): array
9598
{
9699
return ['fields'];
@@ -109,6 +112,9 @@ public function getTargets(): string|array
109112
return self::CLASS_CONSTRAINT;
110113
}
111114

115+
/**
116+
* @deprecated since Symfony 7.4
117+
*/
112118
public function getDefaultOption(): ?string
113119
{
114120
return 'fields';

src/Symfony/Component/Validator/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ CHANGELOG
44
7.4
55
---
66

7+
* Deprecate `getRequiredOptions()` and `getDefaultOption()` methods of the `All`, `AtLeastOneOf`, `CardScheme`, `Collection`,
8+
`CssColor`, `Expression`, `Regex`, `Sequentially`, `Type`, and `When` constraints
79
* Deprecate evaluating options in the base `Constraint` class. Initialize properties in the constructor of the concrete constraint
810
class instead.
911

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy