Skip to content

Benefit from static analysis #622

Closed
@szepeviktor

Description

@szepeviktor

Bug Description

There are errors in the code.
e.g. webp_uploads_update_image_onchange: Callback expects 5 parameters, $accepted_args is set to 7.

Steps to reproduce

  1. composer require --dev szepeviktor/phpstan-wordpress
  2. vendor/bin/phpstan analyse -c vendor/szepeviktor/phpstan-wordpress/extension.neon admin/ modules/ server-timing/ *.php --level=0 then raise level by one
  3. Benefit!

Please consider using PHPStan.
Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    InfrastructureIssues for the overall performance plugin infrastructure[Plugin] Performance LabIssue relates to work in the Performance Lab Plugin only[Type] BugAn existing feature is broken

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions