3.0.x: Fix coding standard related errors

Created on 10 February 2023, almost 2 years ago
Updated 2 March 2023, almost 2 years ago

phpcs report


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/css/sharethis.form.css
------------------------------------------------------------------------------------------------
FOUND 5 ERRORS AFFECTING 5 LINES
------------------------------------------------------------------------------------------------
  13 | ERROR | [ ] Style definitions must end with a semicolon
  23 | ERROR | [x] CSS colours must be defined in lowercase; expected #056d2d but found #056D2D
  35 | ERROR | [ ] Style definitions must end with a semicolon
  44 | ERROR | [ ] Style definitions must end with a semicolon
 144 | ERROR | [ ] Style definitions must end with a semicolon
------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------------------------------


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/css/stlib_picker.css
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
 32 | ERROR | Style definitions must end with a semicolon
----------------------------------------------------------------------


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/SharethisConfigFormTest.php
-----------------------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AND 4 WARNINGS AFFECTING 5 LINES
-----------------------------------------------------------------------------------------------------------------------------------------
 48 | ERROR   | The array declaration extends to column 91 (the limit is 80). The array content should be split up over multiple lines
 59 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 60 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 84 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 85 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
-----------------------------------------------------------------------------------------------------------------------------------------


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/ShareThisTest.php
-----------------------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
-----------------------------------------------------------------------------------------------------------------------------------------
 41 | ERROR   | The array declaration extends to column 88 (the limit is 80). The array content should be split up over multiple lines
 54 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
-----------------------------------------------------------------------------------------------------------------------------------------


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/Views/SharethisViewsPluginTest.php
--------------------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------------------------------------------------------------
 53 | ERROR | The array declaration extends to column 116 (the limit is 80). The array content should be split up over multiple lines
--------------------------------------------------------------------------------------------------------------------------------------


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/SharethisBlockTest.php
-----------------------------------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 4 WARNINGS AFFECTING 4 LINES
-----------------------------------------------------------------------------------------------------------------------------------------
 47 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 48 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 60 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 61 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
-----------------------------------------------------------------------------------------------------------------------------------------


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/src/Form/SharethisConfigurationForm.php
----------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
----------------------------------------------------------------------------------------------
 117 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
----------------------------------------------------------------------------------------------


FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/src/SharethisManager.php
----------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
----------------------------------------------------------------------------------------------------------------
  7 | WARNING | [x] Unused use statement
 81 | WARNING | [ ] NodeType::loadMultiple calls should be avoided in classes, use dependency injection instead
----------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------------------------

Time: 794ms; Memory: 12MB


๐Ÿ› Bug report
Status

Fixed

Version

3.0

Component

Code

Created by

๐Ÿ‡ฆ๐Ÿ‡บAustralia VladimirAus Brisbane, Australia

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @VladimirAus
  • @vladimiraus opened merge request.
  • Status changed to Needs work almost 2 years ago
  • ๐Ÿ‡ฆ๐Ÿ‡บAustralia VladimirAus Brisbane, Australia

    ๐Ÿค– Automated fixes applied.
    ๐Ÿ—๏ธ More work required

    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/css/sharethis.form.css
    ----------------------------------------------------------------------
    FOUND 4 ERRORS AFFECTING 4 LINES
    ----------------------------------------------------------------------
      13 | ERROR | Style definitions must end with a semicolon
      35 | ERROR | Style definitions must end with a semicolon
      44 | ERROR | Style definitions must end with a semicolon
     144 | ERROR | Style definitions must end with a semicolon
    ----------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/css/stlib_picker.css
    ----------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    ----------------------------------------------------------------------
     32 | ERROR | Style definitions must end with a semicolon
    ----------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/SharethisConfigFormTest.php
    -----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AND 4 WARNINGS AFFECTING 5 LINES
    -----------------------------------------------------------------------------------------------------------------------------------------
     48 | ERROR   | The array declaration extends to column 91 (the limit is 80). The array content should be split up over multiple lines
     59 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
     60 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
     84 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
     85 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
    -----------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/ShareThisTest.php
    -----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
    -----------------------------------------------------------------------------------------------------------------------------------------
     41 | ERROR   | The array declaration extends to column 88 (the limit is 80). The array content should be split up over multiple lines
     54 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
    -----------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/Views/SharethisViewsPluginTest.php
    --------------------------------------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    --------------------------------------------------------------------------------------------------------------------------------------
     53 | ERROR | The array declaration extends to column 116 (the limit is 80). The array content should be split up over multiple lines
    --------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/tests/src/Functional/SharethisBlockTest.php
    -----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 4 WARNINGS AFFECTING 4 LINES
    -----------------------------------------------------------------------------------------------------------------------------------------
     47 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
     48 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
     60 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
     61 | WARNING | t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
    -----------------------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/src/Form/SharethisConfigurationForm.php
    ----------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    ----------------------------------------------------------------------------------------------
     117 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
    ----------------------------------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/src/SharethisManager.php
    ------------------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    ------------------------------------------------------------------------------------------------------------
     80 | WARNING | NodeType::loadMultiple calls should be avoided in classes, use dependency injection instead
    ------------------------------------------------------------------------------------------------------------
    
    Time: 809ms; Memory: 12MB
    
    
    
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia rassoni Bangalore

    Rashmisoni โ†’ made their first commit to this issueโ€™s fork.

  • Status changed to Needs review almost 2 years ago
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia rassoni Bangalore

    Fixed #4 issues in MR.

  • Assigned to sourabhjain
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia sourabhjain

    Let me review this.

  • Issue was unassigned.
  • Status changed to Needs work almost 2 years ago
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia rajneeshb New Delhi

    Reviewed merge request !6. These issue still there

    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/src/Form/SharethisConfigurationForm.php
    ----------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    ----------------------------------------------------------------------------------------------
     117 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
    ----------------------------------------------------------------------------------------------
    
    
    FILE: /Users/tesboss/_PROJECTS/drupal/sharethis/src/SharethisManager.php
    ------------------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    ------------------------------------------------------------------------------------------------------------
     80 | WARNING | NodeType::loadMultiple calls should be avoided in classes, use dependency injection instead
    ------------------------------------------------------------------------------------------------------------
  • Status changed to Needs review almost 2 years ago
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia rassoni Bangalore
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia rajneeshb New Delhi

    Reviewed merge request 6. All coding standard issues fixed. Looks good tom me + 1 RTBC

  • Status changed to RTBC almost 2 years ago
  • ๐Ÿ‡ฆ๐Ÿ‡บAustralia VladimirAus Brisbane, Australia

    Great work! Thanks! ๐Ÿฅƒ

  • Status changed to Fixed almost 2 years ago
  • ๐Ÿ‡ฆ๐Ÿ‡บAustralia VladimirAus Brisbane, Australia
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024