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
I installed the dependency through the command: composer require --dev magento/magento-coding-standard
Then I executed the command: ./vendor/bin/phpcs --standard=Magento2 /path/to/file/MassDelete.php
And I got the following result:
FILE: /path/to/file/MassDelete.php
--------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------------------------------------
27 | WARNING | Use ::class notation instead.
--------------------------------------------------------------------------------------------------------------
Time: 1.02 secs; Memory: 8MB
However, on another computer, performing the same procedure, the following result is displayed:
FILE: /path/to/file/MassDelete.php
---------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 3 LINES
---------------------------------------------------------------------------------------------------------------
27 | WARNING | The direct use of ObjectManager is discouraged. Inject necessary dependencies via constructor.
28 | WARNING | Model LSD method load() detected in loop
29 | WARNING | Model LSD method delete() detected in loop
---------------------------------------------------------------------------------------------------------------
Expected result
The same result in both environments
Actually, how to validate LSD/loop and "direct use of ObjectManager" once there is no Sniff for that in the current version?
Actual result
Different results
How can I have 2 different results for the same command in different computers?
The text was updated successfully, but these errors were encountered:
Steps to reproduce
I installed the dependency through the command:
composer require --dev magento/magento-coding-standard
Then I executed the command:
./vendor/bin/phpcs --standard=Magento2 /path/to/file/MassDelete.php
And I got the following result:
However, on another computer, performing the same procedure, the following result is displayed:
Expected result
Actual result
The text was updated successfully, but these errors were encountered: