Skip to content

Commit 687ad65

Browse files
committed
minor symfony#24149 [CS] Apply phpdoc_annotation_without_dot (keradus)
This PR was squashed before being merged into the 2.7 branch (closes symfony#24149). Discussion ---------- [CS] Apply phpdoc_annotation_without_dot | Q | A | ------------- | --- | Branch? | 2.7 | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | n/a | Fixed tickets | n/a | License | MIT | Doc PR | n/a Rule was manually applied here : symfony#19198 In same PR, fixer for this rule was requested, later implementation was approved by Symfony in PHP-CS-Fixer/PHP-CS-Fixer#2020 . Rule is converting single sentence to not a sentence, dropping final dot and lowercasing first word. If there are multiple sentences, it doesn't make any changes. Status quo is that some annotation are in the middle - having first word uppercased, but no final stop. Let us fix grammar by finishing applying the rule. If, for some reason, you don't want to follow that rule that was requested by Symfony, please provide reasoning. If it's to some edge-case bug, simply raise that bug issue. If due to some other reasons, please send a PR to drop it from `@Symfony` ruleset. Info: I did manually reviewed every single change of this PR. Commits ------- 7a97b49 [CS] Apply phpdoc_annotation_without_dot
2 parents bcfe152 + 7a97b49 commit 687ad65

File tree

93 files changed

+301
-303
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

93 files changed

+301
-303
lines changed

.php_cs.dist

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ return PhpCsFixer\Config::create()
1212
'no_unreachable_default_argument_value' => false,
1313
'braces' => array('allow_single_line_closure' => true),
1414
'heredoc_to_nowdoc' => false,
15-
'phpdoc_annotation_without_dot' => false,
1615
))
1716
->setRiskyAllowed(true)
1817
->setFinder(

src/Symfony/Bridge/Doctrine/DependencyInjection/AbstractDoctrineExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ protected function detectMetadataDriver($dir, ContainerBuilder $container)
301301
* @param ContainerBuilder $container A ContainerBuilder instance
302302
* @param string $cacheName
303303
*
304-
* @throws \InvalidArgumentException In case of unknown driver type.
304+
* @throws \InvalidArgumentException in case of unknown driver type
305305
*/
306306
protected function loadObjectManagerCacheDriver(array $objectManager, ContainerBuilder $container, $cacheName)
307307
{

src/Symfony/Bridge/Doctrine/DependencyInjection/CompilerPass/RegisterMappingsPass.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -108,15 +108,15 @@ abstract class RegisterMappingsPass implements CompilerPassInterface
108108
*
109109
* @param Definition|Reference $driver Driver DI definition or reference
110110
* @param string[] $namespaces List of namespaces handled by $driver
111-
* @param string[] $managerParameters List of container parameters that could
112-
* hold the manager name.
111+
* @param string[] $managerParameters list of container parameters that could
112+
* hold the manager name
113113
* @param string $driverPattern Pattern for the metadata driver service name
114114
* @param string|false $enabledParameter Service container parameter that must be
115115
* present to enable the mapping. Set to false
116116
* to not do any check, optional.
117117
* @param string $configurationPattern Pattern for the Configuration service name
118-
* @param string $registerAliasMethodName Name of Configuration class method to
119-
* register alias.
118+
* @param string $registerAliasMethodName name of Configuration class method to
119+
* register alias
120120
* @param string[] $aliasMap Map of alias to namespace
121121
*/
122122
public function __construct($driver, array $namespaces, array $managerParameters, $driverPattern, $enabledParameter = false, $configurationPattern = '', $registerAliasMethodName = '', array $aliasMap = array())
@@ -174,7 +174,7 @@ public function process(ContainerBuilder $container)
174174
* @return string The name of the chain driver service
175175
*
176176
* @throws ParameterNotFoundException if non of the managerParameters has a
177-
* non-empty value.
177+
* non-empty value
178178
*/
179179
protected function getChainDriverServiceName(ContainerBuilder $container)
180180
{
@@ -185,7 +185,7 @@ protected function getChainDriverServiceName(ContainerBuilder $container)
185185
* Create the service definition for the metadata driver.
186186
*
187187
* @param ContainerBuilder $container passed on in case an extending class
188-
* needs access to the container.
188+
* needs access to the container
189189
*
190190
* @return Definition|Reference the metadata driver to add to all chain drivers
191191
*/
@@ -202,7 +202,7 @@ protected function getDriver(ContainerBuilder $container)
202202
* @return string a service definition name
203203
*
204204
* @throws ParameterNotFoundException if none of the managerParameters has a
205-
* non-empty value.
205+
* non-empty value
206206
*/
207207
private function getConfigurationServiceName(ContainerBuilder $container)
208208
{
@@ -219,7 +219,7 @@ private function getConfigurationServiceName(ContainerBuilder $container)
219219
*
220220
* @return string The name of the active manager
221221
*
222-
* @throws ParameterNotFoundException If none of the managerParameters is found in the container.
222+
* @throws ParameterNotFoundException if none of the managerParameters is found in the container
223223
*/
224224
private function getManagerName(ContainerBuilder $container)
225225
{

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,8 @@ class DoctrineChoiceLoader implements ChoiceLoaderInterface
6565
* @param ObjectManager $manager The object manager
6666
* @param string $class The class name of the
6767
* loaded objects
68-
* @param IdReader $idReader The reader for the object
69-
* IDs.
68+
* @param IdReader $idReader the reader for the object
69+
* IDs
7070
* @param null|EntityLoaderInterface $objectLoader The objects loader
7171
*/
7272
public function __construct(ChoiceListFactoryInterface $factory, ObjectManager $manager, $class, IdReader $idReader = null, EntityLoaderInterface $objectLoader = null)

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -389,8 +389,8 @@ public function getIndicesForValues(array $values)
389389
*
390390
* @param mixed $entity The choice to create an index for
391391
*
392-
* @return int|string A unique index containing only ASCII letters,
393-
* digits and underscores.
392+
* @return int|string a unique index containing only ASCII letters,
393+
* digits and underscores
394394
*/
395395
protected function createIndex($entity)
396396
{

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

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
*
2121
* @author Bernhard Schussek <[email protected]>
2222
*
23-
* @internal This class is meant for internal use only.
23+
* @internal this class is meant for internal use only
2424
*/
2525
class IdReader
2626
{
@@ -79,8 +79,8 @@ public function __construct(ObjectManager $om, ClassMetadata $classMetadata)
7979
/**
8080
* Returns whether the class has a single-column ID.
8181
*
82-
* @return bool Returns `true` if the class has a single-column ID and
83-
* `false` otherwise.
82+
* @return bool returns `true` if the class has a single-column ID and
83+
* `false` otherwise
8484
*/
8585
public function isSingleId()
8686
{
@@ -90,8 +90,8 @@ public function isSingleId()
9090
/**
9191
* Returns whether the class has a single-column integer ID.
9292
*
93-
* @return bool Returns `true` if the class has a single-column integer ID
94-
* and `false` otherwise.
93+
* @return bool returns `true` if the class has a single-column integer ID
94+
* and `false` otherwise
9595
*/
9696
public function isIntId()
9797
{

src/Symfony/Bundle/FrameworkBundle/Templating/Helper/FormHelper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ public function block(FormView $view, $blockName, array $variables = array())
257257
*
258258
* @return string A CSRF token
259259
*
260-
* @throws \BadMethodCallException When no CSRF provider was injected in the constructor.
260+
* @throws \BadMethodCallException when no CSRF provider was injected in the constructor
261261
*/
262262
public function csrfToken($intention)
263263
{

src/Symfony/Component/Config/Definition/BaseNode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ abstract class BaseNode implements NodeInterface
3838
* @param string $name The name of the node
3939
* @param NodeInterface $parent The parent of this node
4040
*
41-
* @throws \InvalidArgumentException if the name contains a period.
41+
* @throws \InvalidArgumentException if the name contains a period
4242
*/
4343
public function __construct($name, NodeInterface $parent = null)
4444
{

src/Symfony/Component/Config/Definition/Builder/ArrayNodeDefinition.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,10 +97,10 @@ public function addDefaultsIfNotSet()
9797
/**
9898
* Adds children with a default value when none are defined.
9999
*
100-
* @param int|string|array|null $children The number of children|The child name|The children names to be added
101-
*
102100
* This method is applicable to prototype nodes only.
103101
*
102+
* @param int|string|array|null $children the number of children|The child name|The children names to be added
103+
*
104104
* @return $this
105105
*/
106106
public function addDefaultChildrenIfNoneSet($children = null)

src/Symfony/Component/Console/Question/Question.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ public function getValidator()
187187
*
188188
* @return $this
189189
*
190-
* @throws \InvalidArgumentException In case the number of attempts is invalid.
190+
* @throws \InvalidArgumentException in case the number of attempts is invalid
191191
*/
192192
public function setMaxAttempts($attempts)
193193
{

0 commit comments

Comments
 (0)