Problem/Motivation

A number phpstan warnings appear in the pipeline with the addition of gitlab ci in #3516929: Add GitLab CI.

Address the following:

------ ----------------------------------------------------------------------- 
  Line   src/Entity/MediaLinkEnhancementsMedia.php                              
 ------ ----------------------------------------------------------------------- 
  21     Instantiated class                                                     
         Drupal\media_link_enhancements\Entity\EntityMalformedException not     
         found.                                                                 
         🪪  class.notFound                                                     
         💡  Learn more at https://phpstan.org/user-guide/discovering-symbols   
  29     Call to method isDefaultRevision() on an unknown class                 
         Drupal\media_link_enhancements\Entity\RevisionableInterface.           
         🪪  class.notFound                                                     
         💡  Learn more at https://phpstan.org/user-guide/discovering-symbols   
  29     Class Drupal\media_link_enhancements\Entity\RevisionableInterface not  
         found.                                                                 
         🪪  class.notFound                                                     
         💡  Learn more at https://phpstan.org/user-guide/discovering-symbols   
  63     Instantiated class                                                     
         Drupal\media_link_enhancements\Entity\UndefinedLinkTemplateException   
         not found.                                                             
         🪪  class.notFound                                                     
         💡  Learn more at https://phpstan.org/user-guide/discovering-symbols   
 ------ ----------------------------------------------------------------------- 
 ------ ---------------------------------------------------------------------- 
  Line   src/Form/MediaLinkEnhancementsAdminForm.php                           
 ------ ---------------------------------------------------------------------- 
  70     Method Drupal\Core\Form\ConfigFormBase::__construct() invoked with 1  
         parameter, 2 required.                                                
         🪪  arguments.count                                                   
 ------ ---------------------------------------------------------------------- 
 ------ ----------------------------------------------------------------------- 
  Line   src/Plugin/Linkit/Matcher/MediaLinkEnhancementsMediaEntityMatcher.php  
 ------ ----------------------------------------------------------------------- 
  18     Class                                                                  
         Drupal\media_link_enhancements\Plugin\Linkit\Matcher\MediaLinkEnhance  
         mentsMediaEntityMatcher extends unknown class                          
         Drupal\linkit\Plugin\Linkit\Matcher\EntityMatcher.                     
         💡  Learn more at https://phpstan.org/user-guide/discovering-symbols   
  42     \Drupal calls should be avoided in classes, use dependency injection   
         instead                                                                
         🪪  globalDrupalDependencyInjection.useDependencyInjection             
 ------ ----------------------------------------------------------------------- 
 ------ ----------------------------------------------------------------------- 
  Line   src/Routing/MediaLinkEnhancementsUrlGenerator.php                      
 ------ ----------------------------------------------------------------------- 
  187    Call to an undefined method                                            
         Drupal\media_link_enhancements\Routing\MediaLinkEnhancementsUrlGenera  
         tor::getRouteDebugMessage().                                           
         🪪  method.notFound                                                    
 ------ ----------------------------------------------------------------------- 
 [ERROR] Found 8 errors               
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

jastraat created an issue. See original summary.

jastraat’s picture

Title: Address code quality issues from pipeline. » Address phpstan issues from pipeline.
Issue summary: View changes

jastraat changed the visibility of the branch 2.0.x to hidden.

jastraat’s picture

Version: 1.0.x-dev » 2.0.x-dev

jastraat’s picture

Status: Active » Needs review
jastraat’s picture

Title: Address phpstan issues from pipeline. » Drupal 11 compatibility and address phpstan issues from pipeline
jastraat’s picture

Status: Needs review » Reviewed & tested by the community

Marking reviewed per @TheLoneliestMonk

  • jastraat committed 30de5758 on 2.0.x
    feat: #3559938 Drupal 11 compatibility and address phpstan issues from...
jastraat’s picture

Status: Reviewed & tested by the community » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.