You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On my project, I've got a lot of view files with no File Header but with a first DocBlock declaring vars to avoid bad inspection and use autocomplete.
These files raise an error with the new standard :
5 | ERROR | The file-level docblock must follow the opening PHP tag in the file header
| | (PSR12.Files.FileHeader.IncorrectOrder)
Here is the start of my file :
<?php
use common\models\JobFunction;
/** @var JobFunction $model */
As you can see, this is not a file level docblock and therefore it should not raise this error.
Thank you, have a good day
The text was updated successfully, but these errors were encountered:
gsherwood
changed the title
PSR12.Files.FileHeader.IncorrectOrder detects every first block
PSR12.Files.FileHeader detects @var annotations as file docblocks
Oct 3, 2019
PHPCS Version : 3.5.0
PHP Version : 7.2.19
Hello,
On my project, I've got a lot of view files with no File Header but with a first DocBlock declaring vars to avoid bad inspection and use autocomplete.
These files raise an error with the new standard :
5 | ERROR | The file-level docblock must follow the opening PHP tag in the file header
| | (PSR12.Files.FileHeader.IncorrectOrder)
Here is the start of my file :
As you can see, this is not a file level docblock and therefore it should not raise this error.
Thank you, have a good day
The text was updated successfully, but these errors were encountered: