Problem/Motivation
Getting following error/warnings.
FILE: /var/www/html/modules/contrib/fpdi_print/fpdi_print.module
----------------------------------------------------------------------
FOUND 2 ERRORS AFFECTING 2 LINES
----------------------------------------------------------------------
26 | ERROR | [x] Expected 1 blank line after function; 0 found
49 | ERROR | [x] Expected 1 newline at end of file; 2 found
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: /var/www/html/modules/contrib/fpdi_print/src/Controller/ViewPrintController.php
----------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
----------------------------------------------------------------------------------------------
179 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
214 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
----------------------------------------------------------------------------------------------
FILE: /var/www/html/modules/contrib/fpdi_print/src/Pdf.php
----------------------------------------------------------------------------
FOUND 2 ERRORS AFFECTING 2 LINES
----------------------------------------------------------------------------
67 | ERROR | Public method name "Pdf::Header" is not in lowerCamel format
114 | ERROR | Public method name "Pdf::Footer" is not in lowerCamel format
----------------------------------------------------------------------------
FILE: /var/www/html/modules/contrib/fpdi_print/src/PrintBuilder.php
----------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------------------------------
335 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
----------------------------------------------------------------------------------------------
Time: 2.29 secs; Memory: 6MB
Steps to reproduce
Run following command
phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml modules/contrib/fpdi_print/
Proposed resolution
Above error/warnings need to be fixed.