[2.0.0-beta1] Code quality: Legacy module

Created on 28 July 2024, 4 months ago
Updated 12 August 2024, 3 months ago
 ------ ---------------------------------------------------------------------- 
  Line   modules/ui_patterns_legacy/src/ComponentConverter.php                 
 ------ ---------------------------------------------------------------------- 
  202    Cannot access offset 1 on array<int, string>|false.                   
  230    \Drupal calls should be avoided in classes, use dependency injection  
         instead                                                               
 ------ ---------------------------------------------------------------------- 
 ------ --------------------------------------------------------------- 
  Line   modules/ui_patterns_legacy/src/ComponentDiscovery.php          
 ------ --------------------------------------------------------------- 
  48     Parameter #1 $raw of static method                             
         Drupal\Component\Serialization\Yaml::decode() expects string,  
         string|false given.                                            
 ------ --------------------------------------------------------------- 
 ------ ----------------------------------------------------------------------------- 
  Line   modules/ui_patterns_legacy/src/Drush/Commands/UiPatternsLegacyCommands.php   
 ------ ----------------------------------------------------------------------------- 
  34     Method                                                                       
         Drupal\ui_patterns_legacy\Drush\Commands\UiPatternsLegacyCommands::create()  
         has no return type specified.                                                
  98     Parameter #3 $subject of function str_replace expects array|string,          
         string|false given.                                                          
  109    Parameter #3 $subject of function preg_replace expects array|string,         
         string|false given.                                                          
  119    Parameter #1 $json of function json_decode expects string,                   
         string|false given.                                                          
 ------ ----------------------------------------------------------------------------- 
 ------ ----------------------------------------------------------------------- 
  Line   modules/ui_patterns_legacy/src/Element/ComponentElementAlter.php       
 ------ ----------------------------------------------------------------------- 
  27     \Drupal calls should be avoided in classes, use dependency injection   
         instead                                                                
  43     \Drupal calls should be avoided in classes, use dependency injection   
         instead                                                                
  52     \Drupal calls should be avoided in classes, use dependency injection   
         instead                                                                
  66     Method                                                                 
         Drupal\ui_patterns_legacy\Element\ComponentElementAlter::getStoryId()  
         should return string but returns int|string|null.                      
 ------ ----------------------------------------------------------------------- 
 ------ ---------------------------------------------------------------------- 
  Line   modules/ui_patterns_legacy/src/RenderableConverter.php                
 ------ ---------------------------------------------------------------------- 
  158    \Drupal calls should be avoided in classes, use dependency injection  
         instead                                                               
  187    \Drupal calls should be avoided in classes, use dependency injection  
         instead                                                               
  209    Cannot access offset 'machineName' on                                 
         array|Drupal\Component\Plugin\Definition\PluginDefinitionInterface.   
 ------ ---------------------------------------------------------------------- 
 ------ -------------------------------------------------------------------------- 
  Line   modules/ui_patterns_legacy/src/StoryExtractor.php                         
 ------ -------------------------------------------------------------------------- 
  90     Method Drupal\ui_patterns_legacy\StoryExtractor::getPropFromSetting()     
         has parameter $key with no type specified.                                
  114    Method                                                                    
         Drupal\ui_patterns_legacy\StoryExtractor::getPropFromSelectSetting()      
         has parameter $key with no type specified.                                
  128    Method                                                                    
         Drupal\ui_patterns_legacy\StoryExtractor::getPropFromCheckboxesSetting()  
         has parameter $key with no type specified.                                
  156    Method Drupal\ui_patterns_legacy\StoryExtractor::convertAttributes()      
         has parameter $key with no type specified.                                
 ------ -------------------------------------------------------------------------- 
 ------ --------------------------------------------------------------------- 
  Line   modules/ui_patterns_legacy/ui_patterns_legacy.module                 
 ------ --------------------------------------------------------------------- 
  13     Function ui_patterns_legacy_element_info_alter() has no return type  
         specified.                                                           
📌 Task
Status

Fixed

Version

2.0

Component

UI Patterns Legacy [2.x only]

Created by

🇫🇷France pdureau Paris

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

Merge Requests

Comments & Activities

Production build 0.71.5 2024