diff --git a/.editorconfig b/.editorconfig index c6f3cf49588a3..289d8b13da1d7 100644 --- a/.editorconfig +++ b/.editorconfig @@ -13,7 +13,7 @@ insert_final_newline = true trim_trailing_whitespace = true indent_style = tab -[*.yml] +[{*.yml}] indent_style = space indent_size = 2 diff --git a/.github/workflows/php-static-analysis.yml b/.github/workflows/php-static-analysis.yml new file mode 100644 index 0000000000000..9b15ee6f9f0fe --- /dev/null +++ b/.github/workflows/php-static-analysis.yml @@ -0,0 +1,100 @@ +name: PHPStan Static Analysis + +on: + # PHPStan testing was introduced in @todo. + push: + branches: + - trunk + - '6.9' + - '[7-9].[0-9]' + tags: + - '6.9' + - '6.9.[0-9]+' + - '[7-9].[0-9]' + - '[7-9]+.[0-9].[0-9]+' + pull_request: + branches: + - trunk + - '6.9' + - '[7-9].[0-9]' + paths: + # This workflow only scans PHP files. + - '**.php' + # These files configure Composer. Changes could affect the outcome. + - 'composer.*' + # These files configure PHPStan. Changes could affect the outcome. + - 'phpstan.neon.dist' + - 'tests/phpstan/base.neon' + # Confirm any changes to relevant workflow files. + - '.github/workflows/php-static-analysis.yml' + - '.github/workflows/reusable-php-static-analysis.yml' + workflow_dispatch: + +# Cancels all previous workflow runs for pull requests that have not completed. +concurrency: + # The concurrency group contains the workflow name and the branch name for pull requests + # or the commit hash for any other events. + group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }} + cancel-in-progress: true + +# Disable permissions for all available scopes by default. +# Any needed permissions should be configured at the job level. +permissions: {} + +jobs: + # Runs PHPStan Static Analysis. + phpstan: + name: PHP coding standards + uses: ./.github/workflows/reusable-php-static-analysis.yml + permissions: + contents: read + if: ${{ github.repository == 'WordPress/wordpress-develop' || ( github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' ) }} + + slack-notifications: + name: Slack Notifications + uses: ./.github/workflows/slack-notifications.yml + permissions: + actions: read + contents: read + needs: [ phpstan ] + if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' && always() }} + with: + calling_status: ${{ contains( needs.*.result, 'cancelled' ) && 'cancelled' || contains( needs.*.result, 'failure' ) && 'failure' || 'success' }} + secrets: + SLACK_GHA_SUCCESS_WEBHOOK: ${{ secrets.SLACK_GHA_SUCCESS_WEBHOOK }} + SLACK_GHA_CANCELLED_WEBHOOK: ${{ secrets.SLACK_GHA_CANCELLED_WEBHOOK }} + SLACK_GHA_FIXED_WEBHOOK: ${{ secrets.SLACK_GHA_FIXED_WEBHOOK }} + SLACK_GHA_FAILURE_WEBHOOK: ${{ secrets.SLACK_GHA_FAILURE_WEBHOOK }} + + failed-workflow: + name: Failed workflow tasks + runs-on: ubuntu-24.04 + permissions: + actions: write + needs: [ slack-notifications ] + if: | + always() && + github.repository == 'WordPress/wordpress-develop' && + github.event_name != 'pull_request' && + github.run_attempt < 2 && + ( + contains( needs.*.result, 'cancelled' ) || + contains( needs.*.result, 'failure' ) + ) + + steps: + - name: Dispatch workflow run + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 + with: + retries: 2 + retry-exempt-status-codes: 418 + script: | + github.rest.actions.createWorkflowDispatch({ + owner: context.repo.owner, + repo: context.repo.repo, + workflow_id: 'failed-workflow.yml', + ref: 'trunk', + inputs: { + run_id: `${context.runId}`, + } + }); diff --git a/.github/workflows/phpunit-tests.yml b/.github/workflows/phpunit-tests.yml index 420506d42265c..3d74105056c8e 100644 --- a/.github/workflows/phpunit-tests.yml +++ b/.github/workflows/phpunit-tests.yml @@ -70,7 +70,7 @@ jobs: fail-fast: false matrix: os: [ ubuntu-24.04 ] - php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ] + php: [ '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ] db-type: [ 'mysql' ] db-version: [ '5.7', '8.0', '8.4' ] tests-domain: [ 'example.org' ] @@ -147,7 +147,7 @@ jobs: fail-fast: false matrix: os: [ ubuntu-24.04 ] - php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ] + php: [ '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ] db-type: [ 'mariadb' ] db-version: [ '5.5', '10.3', '10.4', '10.5', '10.6', '10.11', '11.4', '11.8' ] multisite: [ false, true ] @@ -199,7 +199,7 @@ jobs: fail-fast: false matrix: os: [ ubuntu-24.04 ] - php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ] + php: [ '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ] db-type: [ 'mysql' ] db-version: [ '9.4' ] multisite: [ false, true ] @@ -241,7 +241,7 @@ jobs: strategy: fail-fast: false matrix: - php: [ '7.2', '7.4', '8.0', '8.4' ] + php: [ '7.4', '8.0', '8.4' ] db-type: [ 'mysql' ] db-version: [ '8.4' ] phpunit-test-groups: [ 'html-api-html5lib-tests' ] diff --git a/.github/workflows/reusable-php-static-analysis.yml b/.github/workflows/reusable-php-static-analysis.yml new file mode 100644 index 0000000000000..7dc01aec24ad4 --- /dev/null +++ b/.github/workflows/reusable-php-static-analysis.yml @@ -0,0 +1,95 @@ +## +# A reusable workflow that runs PHP Static Analysis tests. +## +name: PHP Static Analysis + +on: + workflow_call: + inputs: + php-version: + description: 'The PHP version to use.' + required: false + type: 'string' + default: 'latest' + +# Disable permissions for all available scopes by default. +# Any needed permissions should be configured at the job level. +permissions: {} + +jobs: + # Runs PHP static analysis tests. + # + # Violations are reported inline with annotations. + # + # Performs the following steps: + # - Checks out the repository. + # - Sets up PHP. + # - Logs debug information. + # - Installs Composer dependencies. + # - Configures caching for PHP static analysis scans. + # - Make Composer packages available globally. + # - Runs PHPStan static analysis (with Pull Request annotations). + # - Saves the PHPStan result cache. + # - Ensures version-controlled files are not modified or deleted. + phpstan: + name: Run PHP static analysis + runs-on: ubuntu-24.04 + permissions: + contents: read + timeout-minutes: 20 + + steps: + - name: Checkout repository + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 + with: + show-progress: ${{ runner.debug == '1' && 'true' || 'false' }} + persist-credentials: false + + - name: Set up PHP + uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0 + with: + php-version: ${{ inputs.php-version }} + coverage: none + tools: cs2pr + + - name: Log debug information + run: | + composer --version + + # This date is used to ensure that the Composer cache is cleared at least once every week. + # http://man7.org/linux/man-pages/man1/date.1.html + - name: "Get last Monday's date" + id: get-date + run: echo "date=$(/bin/date -u --date='last Mon' "+%F")" >> "$GITHUB_OUTPUT" + + # Since Composer dependencies are installed using `composer update` and no lock file is in version control, + # passing a custom cache suffix ensures that the cache is flushed at least once per week. + - name: Install Composer dependencies + uses: ramsey/composer-install@a2636af0004d1c0499ffca16ac0b4cc94df70565 # v3.1.0 + with: + custom-cache-suffix: ${{ steps.get-date.outputs.date }} + + - name: Make Composer packages available globally + run: echo "${PWD}/vendor/bin" >> "$GITHUB_PATH" + + - name: Cache PHP Static Analysis scan cache + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3 + with: + path: .cache # This is defined in the base.neon file. + key: "phpstan-result-cache-${{ github.run_id }}" + restore-keys: | + phpstan-result-cache- + + - name: Run PHP static analysis tests + id: phpstan + run: phpstan analyse -vvv --error-format=checkstyle | cs2pr + + - name: "Save result cache" + uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3 + if: ${{ !cancelled() }} + with: + path: .cache + key: "phpstan-result-cache-${{ github.run_id }}" + + - name: Ensure version-controlled files are not modified or deleted + run: git diff --exit-code diff --git a/.gitignore b/.gitignore index 648c711b21f26..b8dc163600f67 100644 --- a/.gitignore +++ b/.gitignore @@ -22,6 +22,7 @@ wp-tests-config.php /build /tests/phpunit/build /wp-cli.local.yml +/phpstan.neon /jsdoc /composer.lock /vendor diff --git a/.version-support-php.json b/.version-support-php.json index b2298e7177fff..38cad5db44851 100644 --- a/.version-support-php.json +++ b/.version-support-php.json @@ -1,7 +1,5 @@ { "6-9": [ - "7.2", - "7.3", "7.4", "8.0", "8.1", diff --git a/composer.json b/composer.json index 2de1e628ffc6c..cc27934143025 100644 --- a/composer.json +++ b/composer.json @@ -23,6 +23,7 @@ "squizlabs/php_codesniffer": "3.13.2", "wp-coding-standards/wpcs": "~3.2.0", "phpcompatibility/phpcompatibility-wp": "~2.1.3", + "phpstan/phpstan": "~2.1.19", "yoast/phpunit-polyfills": "^1.1.0" }, "config": { @@ -32,6 +33,7 @@ "lock": false }, "scripts": { + "analyse": "@php ./vendor/bin/phpstan analyse --memory-limit=2G", "compat": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcs --standard=phpcompat.xml.dist --report=summary,source", "format": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcbf --report=summary,source", "lint": "@php ./vendor/squizlabs/php_codesniffer/bin/phpcs --report=summary,source", diff --git a/phpcs.xml.dist b/phpcs.xml.dist index 636580a4040d9..2c1d70acf2535 100644 --- a/phpcs.xml.dist +++ b/phpcs.xml.dist @@ -81,6 +81,9 @@ /tests/phpunit/build* /tests/phpunit/data/* + + /tests/phpstan/* + /tools/* diff --git a/phpstan.neon.dist b/phpstan.neon.dist new file mode 100644 index 0000000000000..d67d63bd45bc1 --- /dev/null +++ b/phpstan.neon.dist @@ -0,0 +1,42 @@ +# PHPStan configuration for WordPress Core. +# +# To overload this configuration, copy this file to phpstan.neon and adjust as needed. +# +# https://phpstan.org/config-reference + +includes: + # The WordPress Core configuration file includes the base configuration for the WordPress codebase. + - tests/phpstan/base.neon + # The baseline file includes preexisting errors in the codebase that should be ignored. + # https://phpstan.org/user-guide/baseline + - tests/phpstan/baseline/level-0.php + - tests/phpstan/baseline/level-1.php + - tests/phpstan/baseline/level-2.php + - tests/phpstan/baseline/level-3.php + - tests/phpstan/baseline/level-4.php + - tests/phpstan/baseline/level-5.php + - tests/phpstan/baseline/level-6.php + +parameters: + level: 6 + reportUnmatchedIgnoredErrors: true + + ignoreErrors: + # Level 0: + - # Inner functions arent supported by PHPstan. + message: '#Function wxr_[a-z_]+ not found#' + path: src/wp-admin/includes/export.php + + # Level 1: + - # These are too noisy at the moment. + message: '#Variable \$[a-zA-Z0-9_]+ might not be defined\.#' + + # Level 2: + - # Callable-strings are used as callables in WordPress. + message: '#Default value of the parameter .* is incompatible with type callable.*#' + + # Level 6: + - # WPCS syntax for iterable types is not supported. + identifier: missingType.iterableValue + - # Too noisy until `void` return types are allowed. + identifier: missingType.return diff --git a/tests/phpstan/base.neon b/tests/phpstan/base.neon new file mode 100644 index 0000000000000..28264355d75e1 --- /dev/null +++ b/tests/phpstan/base.neon @@ -0,0 +1,126 @@ +# Base PHPStan configuration for WordPress Core. +# +# This is kept separate from the main PHPStan configuration file to allow for easy overloading while baseline errors are being fixed. +# +# https://phpstan.org/config-reference + +parameters: + # Cache is stored locally, so it's available for CI. + tmpDir: ../../.cache + + # The Minimum PHP Version + phpVersion: + min: 70224 + max: 80400 + + # If it's not enforced by PHP we can't assume users are passing valid values. + treatPhpDocTypesAsCertain: false + + # These config options are explained in https://phpstan.org/config-reference + checkFunctionNameCase: true + inferPrivatePropertyTypeFromConstructor: true + + # Constants whose values may differ depending on the install. + dynamicConstantNames: + - ALLOW_SUBDIRECTORY_INSTALL + - AUTH_SALT + - AUTOMATIC_UPDATER_DISABLED + - COOKIEPATH + - CUSTOM_TAGS + - DISALLOW_FILE_EDIT + - DISALLOW_UNFILTERED_HTML + - EMPTY_TRASH_DAYS + - ENFORCE_GZIP + - FORCE_SSL_LOGIN + - MEDIA_TRASH + - MULTISITE + - NOBLOGREDIRECT + - SAVEQUERIES + - SCRIPT_DEBUG + - SECRET_KEY + - SECRET_SALT + - SHORTINIT + - SITECOOKIEPATH + - UPLOADBLOGSDIR + - WP_ALLOW_MULTISITE + - WP_CACHE + - WP_DEBUG + - WP_DEBUG_DISPLAY + - WP_DEBUG_LOG + - WP_LANG_DIR + - WP_NETWORK_ADMIN + - WP_POST_REVISIONS + - WP_SITEURL + - WP_USE_THEMES + - WP_USER_ADMIN + - WPLANG + - WPMU_ACCEL_REDIRECT + - WPMU_PLUGIN_DIR + - WPMU_SENDFILE + + # What directories and files should be scanned. + paths: + - ../../src + bootstrapFiles: + - bootstrap.php + scanFiles: + - ../../wp-config-sample.php + - ../../src/wp-admin/includes/ms.php + scanDirectories: + - ../../src/wp-includes + - ../../src/wp-admin + excludePaths: + analyseAndScan: + # These files are deprecated and should not be scanned. + - ../../src/wp-admin/includes/deprecated.php + - ../../src/wp-admin/includes/ms-deprecated.php + - ../../src/wp-admin/includes/noop.php + - ../../src/wp-includes/deprecated.php + - ../../src/wp-includes/ms-deprecated.php + - ../../src/wp-includes/pluggable-deprecated.php + # These files are not part of the WordPress Core codebase. + - ../../src/wp-content + # JavaScript/CSS/Asset files. + - ../../src/js + - ../../src/wp-admin/css + - ../../src/wp-admin/images + # These are built from js/_enqueues. + - ../../src/wp-admin/js (?) + - ../../src/wp-includes/js (?) + analyse: + # These files are sourced by wordpress/gutenberg in `tools/release/sync-stable-blocks.js`. + - ../../src/wp-includes/blocks + # Third-party libraries. + - ../../src/js/_enqueues/vendor + - ../../src/wp-admin/includes/class-ftp-pure.php + - ../../src/wp-admin/includes/class-ftp-sockets.php + - ../../src/wp-admin/includes/class-ftp.php + - ../../src/wp-admin/includes/class-pclzip.php + - ../../src/wp-includes/atomlib.php + - ../../src/wp-includes/class-avif-info.php + - ../../src/wp-includes/class-IXR.php + - ../../src/wp-includes/class-json.php + - ../../src/wp-includes/class-phpass.php + - ../../src/wp-includes/class-pop3.php + - ../../src/wp-includes/class-requests.php + - ../../src/wp-includes/class-simplepie.php + - ../../src/wp-includes/class-snoopy.php + - ../../src/wp-includes/class-wp-feed-cache.php + - ../../src/wp-includes/class-wp-http-ixr-client.php + - ../../src/wp-includes/class-wp-http-requests-hooks.php + - ../../src/wp-includes/class-wp-http-requests-response.php + - ../../src/wp-includes/class-wp-simplepie-file.php + - ../../src/wp-includes/class-wp-simplepie-sanitize-kses.php + - ../../src/wp-includes/class-wp-text-diff-renderer-inline.php + - ../../src/wp-includes/class-wp-text-diff-renderer-table.php + - ../../src/wp-includes/rss.php + - ../../src/wp-includes/ID3 + - ../../src/wp-includes/IXR + - ../../src/wp-includes/PHPMailer + - ../../src/wp-includes/pomo + - ../../src/wp-includes/Requests + - ../../src/wp-includes/SimplePie + - ../../src/wp-includes/sodium_compat + - ../../src/wp-includes/Text + # Contains errors that cannot be ignored by PHPStan. + - ../../src/wp-includes/html-api/class-wp-html-processor.php diff --git a/tests/phpstan/baseline/level-0.php b/tests/phpstan/baseline/level-0.php new file mode 100644 index 0000000000000..b0b2ead3aaed7 --- /dev/null +++ b/tests/phpstan/baseline/level-0.php @@ -0,0 +1,95 @@ + '#^Method WP_Filesystem_SSH2\\:\\:touch\\(\\) should return bool but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ssh2.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Inner named functions are not supported by PHPStan\\. Consider refactoring to an anonymous function, class method, or a top\\-level\\-defined function\\. See issue \\#165 \\(https\\://github\\.com/phpstan/phpstan/issues/165\\) for more details\\.$#', + 'identifier' => 'function.inner', + 'count' => 13, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/export.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Inner named functions are not supported by PHPStan\\. Consider refactoring to an anonymous function, class method, or a top\\-level\\-defined function\\. See issue \\#165 \\(https\\://github\\.com/phpstan/phpstan/issues/165\\) for more details\\.$#', + 'identifier' => 'function.inner', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_file not found\\.$#', + 'identifier' => 'function.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/load-scripts.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_file not found\\.$#', + 'identifier' => 'function.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/load-styles.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Instantiated class WP_Press_This_Plugin not found\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/press-this.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Path in include\\(\\) "/press\\-this/class\\-wp\\-press\\-this\\-plugin\\.php" is not a file or it does not exist\\.$#', + 'identifier' => 'include.fileNotFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/press-this.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Inner named functions are not supported by PHPStan\\. Consider refactoring to an anonymous function, class method, or a top\\-level\\-defined function\\. See issue \\#165 \\(https\\://github\\.com/phpstan/phpstan/issues/165\\) for more details\\.$#', + 'identifier' => 'function.inner', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Theme_JSON\\:\\:should_override_preset\\(\\) should return bool but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Customize_Background_Image_Setting\\:\\:update\\(\\) should return bool but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-background-image-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Customize_Filter_Setting\\:\\:update\\(\\) should return bool but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-filter-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Customize_Header_Image_Setting\\:\\:update\\(\\) should return bool but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-header-image-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Class GdImage not found\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe usage of new static\\(\\)\\.$#', + 'identifier' => 'new.static', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/style-engine/class-wp-style-engine-css-rules-store.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Undefined variable\\: \\$s$#', + 'identifier' => 'variable.undefined', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/template.php', +]; + +return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/phpstan/baseline/level-1.php b/tests/phpstan/baseline/level-1.php new file mode 100644 index 0000000000000..3c43c3b2af23a --- /dev/null +++ b/tests/phpstan/baseline/level-1.php @@ -0,0 +1,131 @@ + '#^Call to function compact\\(\\) contains possibly undefined variable \\$comment_author\\.$#', + 'identifier' => 'variable.undefined', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function compact\\(\\) contains possibly undefined variable \\$comment_author_email\\.$#', + 'identifier' => 'variable.undefined', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function compact\\(\\) contains possibly undefined variable \\$comment_author_url\\.$#', + 'identifier' => 'variable.undefined', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function compact\\(\\) contains possibly undefined variable \\$user_id\\.$#', + 'identifier' => 'variable.undefined', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$_POST in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-custom-image-header.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Constructor of class WP_Filesystem_Direct has an unused parameter \\$arg\\.$#', + 'identifier' => 'constructor.unusedParameter', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-direct.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$class in empty\\(\\) always exists and is always falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-posts-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$_POST in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$parent_file in empty\\(\\) always exists and is not falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/themes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$addl_path in empty\\(\\) always exists and is always falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$namespace in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-parser.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$block_type in empty\\(\\) always exists and is not falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-supports.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$loader in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-oembed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$q in isset\\(\\) is never defined\\.$#', + 'identifier' => 'isset.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$search in empty\\(\\) always exists and is not falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$status_type_clauses in empty\\(\\) always exists and is not falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$modes_str in empty\\(\\) always exists and is not falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wpdb.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$deprecated in empty\\(\\) always exists and is always falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$schema in empty\\(\\) is never defined\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$the_parent in empty\\(\\) always exists and is not falsy\\.$#', + 'identifier' => 'empty.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Variable \\$s in isset\\(\\) is never defined\\.$#', + 'identifier' => 'isset.variable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/template.php', +]; + +return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/phpstan/baseline/level-2.php b/tests/phpstan/baseline/level-2.php new file mode 100644 index 0000000000000..c98d4bdacef46 --- /dev/null +++ b/tests/phpstan/baseline/level-2.php @@ -0,0 +1,1217 @@ + '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/_index.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method inline_edit\\(\\) on WP_List_Table\\|false\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/edit-tags.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method inline_edit\\(\\) on WP_List_Table\\|false\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to protected property WP_List_Table\\:\\:\\$screen\\.$#', + 'identifier' => 'property.protected', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/erase-personal-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method embed_scripts\\(\\) on WP_List_Table\\|false\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/erase-personal-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method process_bulk_action\\(\\) on WP_List_Table\\|false\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/erase-personal-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to protected property WP_List_Table\\:\\:\\$screen\\.$#', + 'identifier' => 'property.protected', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/export-personal-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method embed_scripts\\(\\) on WP_List_Table\\|false\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/export-personal-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method process_bulk_action\\(\\) on WP_List_Table\\|false\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/export-personal-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to protected property WP_List_Table\\:\\:\\$screen\\.$#', + 'identifier' => 'property.protected', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$download_link on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$name on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$themes on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method get_error_message\\(\\) on array\\|object\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_List_Table\\:\\:display_rows\\(\\) invoked with 2 parameters, 0 required\\.$#', + 'identifier' => 'arguments.count', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_List_Table\\:\\:single_row\\(\\) invoked with 2 parameters, 1 required\\.$#', + 'identifier' => 'arguments.count', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_List_Table\\:\\:single_row\\(\\) invoked with 3 parameters, 1 required\\.$#', + 'identifier' => 'arguments.count', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to an undefined method WP_Upgrader\\:\\:get_name_for_update\\(\\)\\.$#', + 'identifier' => 'method.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-language-pack-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Upgrader_Skin\\:\\:\\$language_update\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-language-pack-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Upgrader\\:\\:\\$new_plugin_data\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to an undefined method WP_Upgrader\\:\\:plugin_info\\(\\)\\.$#', + 'identifier' => 'method.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to an undefined method WP_Upgrader\\:\\:plugin_info\\(\\)\\.$#', + 'identifier' => 'method.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Upgrader_Skin\\:\\:\\$plugin_active\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Upgrader_Skin\\:\\:\\$plugin_info\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Upgrader_Skin\\:\\:before\\(\\) invoked with 1 parameter, 0 required\\.$#', + 'identifier' => 'arguments.count', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Upgrader\\:\\:\\$new_theme_data\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to an undefined method WP_Upgrader\\:\\:theme_info\\(\\)\\.$#', + 'identifier' => 'method.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to an undefined method WP_Upgrader\\:\\:theme_info\\(\\)\\.$#', + 'identifier' => 'method.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Upgrader_Skin\\:\\:\\$api\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Upgrader_Skin\\:\\:\\$theme_info\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$download_link on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$name on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$version on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Upgrader_Skin\\:\\:before\\(\\) invoked with 1 parameter, 0 required\\.$#', + 'identifier' => 'arguments.count', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$attr_title\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$classes\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$menu_item_parent\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$object\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$object_id\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$target\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$title\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$type\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$url\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$xfn\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$classes\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$description\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$menu_item_parent\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$object\\.$#', + 'identifier' => 'property.notFound', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$object_id\\.$#', + 'identifier' => 'property.notFound', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$target\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$title\\.$#', + 'identifier' => 'property.notFound', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$type\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$type_label\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$url\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$xfn\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$current on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-automatic-updater.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$response on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-automatic-updater.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$version on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-automatic-updater.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Theme\\:\\:\\$author\\.$#', + 'identifier' => 'property.notFound', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Theme\\:\\:\\$name\\.$#', + 'identifier' => 'property.notFound', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Theme\\:\\:\\$parent_theme\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Theme\\:\\:\\$version\\.$#', + 'identifier' => 'property.notFound', + 'count' => 6, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to private property WP_Theme\\:\\:\\$stylesheet\\.$#', + 'identifier' => 'property.private', + 'count' => 20, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to private property WP_Theme\\:\\:\\$template\\.$#', + 'identifier' => 'property.private', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Binary operation "\\+" between non\\-empty\\-string and non\\-empty\\-string results in an error\\.$#', + 'identifier' => 'binaryOp.invalid', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-base.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Default value of the parameter \\#1 \\$opt \\(string\\) of method WP_Filesystem_FTPext\\:\\:__construct\\(\\) is incompatible with type array\\.$#', + 'identifier' => 'parameter.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ftpext.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Default value of the parameter \\#1 \\$opt \\(string\\) of method WP_Filesystem_ftpsockets\\:\\:__construct\\(\\) is incompatible with type array\\.$#', + 'identifier' => 'parameter.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ftpsockets.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Default value of the parameter \\#1 \\$opt \\(string\\) of method WP_Filesystem_SSH2\\:\\:__construct\\(\\) is incompatible with type array\\.$#', + 'identifier' => 'parameter.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ssh2.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Binary operation "\\." between \'http\\://\' and list\\\\|null results in an error\\.$#', + 'identifier' => 'binaryOp.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-importer.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$info on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugin-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$plugins on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugin-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Theme\\:\\:\\$name\\.$#', + 'identifier' => 'property.notFound', + 'count' => 8, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$parent on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-terms-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$term_id on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-terms-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$info on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-theme-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$themes on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-theme-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method get_error_message\\(\\) on array\\|object\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-theme-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\<\\=" between \\(array\\|float\\|int\\) and 0 results in an error\\.$#', + 'identifier' => 'smallerOrEqual.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>" between array\\|float\\|int and 0 results in an error\\.$#', + 'identifier' => 'greater.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _crop_image_resource\\(\\) has invalid return type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _flip_image_resource\\(\\) has invalid return type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _rotate_image_resource\\(\\) has invalid return type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\$img of function _crop_image_resource\\(\\) has invalid type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\$img of function _flip_image_resource\\(\\) has invalid type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\$img of function _rotate_image_resource\\(\\) has invalid type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$_wp_attachment_image_alt on array\\|WP_Post\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function load_image_to_edit\\(\\) has invalid return type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$menu_order on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$post_content on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$post_title on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>" between 1 and array\\\\|int results in an error\\.$#', + 'identifier' => 'greater.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/meta-boxes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_List_Table\\:\\:display\\(\\) invoked with 1 parameter, 0 required\\.$#', + 'identifier' => 'arguments.count', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/meta-boxes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$privacy_policy_page\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$front_or_home on array\\|WP_Post\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method get_error_message\\(\\) on array\\\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$author on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$downloaded on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$homepage on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$name on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$requires on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$sections on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 5, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$slug on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$tested on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$version on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Binary operation "\\*" between string and 1\\.0E\\-5 results in an error\\.$#', + 'identifier' => 'binaryOp.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to private property WP_Block_Type\\:\\:\\$uses_context\\.$#', + 'identifier' => 'property.private', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to private property WP_Block_Type\\:\\:\\$variations\\.$#', + 'identifier' => 'property.private', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$meta_key on object\\|true\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$post_id on object\\|true\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$posts on class\\-string\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Term\\:\\:\\$truncated_name\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/nav-menus.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to method html\\(\\) on an unknown class WP_Press_This_Plugin\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/press-this.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/profile.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Theme\\:\\:\\$version\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/update-core.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$download_link on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/update.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$name on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/update.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$version on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/update.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/upgrade.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$comment_shortcuts on WP_User\\|false\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/user-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-cron.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post_Type\\:\\:\\$capabilities\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/capabilities.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_category_by_path\\(\\) should return array\\|WP_Error\\|WP_Term\\|null but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/category.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$current\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-walker-nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$title\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-walker-nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to private property WP_Block_Type\\:\\:\\$uses_context\\.$#', + 'identifier' => 'property.private', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Classic_To_Block_Menu_Converter\\:\\:group_by_parent_id\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-classic-to-block-menu-converter.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Classic_To_Block_Menu_Converter\\:\\:to_blocks\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-classic-to-block-menu-converter.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$themes on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Binary operation "/" between string and 255 results in an error\\.$#', + 'identifier' => 'binaryOp.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-duotone.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @param for parameter \\$type contains unresolvable type\\.$#', + 'identifier' => 'parameter.unresolvableType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-feed-cache-transient.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Default value of the parameter \\#1 \\$width \\(false\\) of method WP_Image_Editor_GD\\:\\:update_size\\(\\) is incompatible with type int\\.$#', + 'identifier' => 'parameter.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-gd.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Default value of the parameter \\#2 \\$height \\(false\\) of method WP_Image_Editor_GD\\:\\:update_size\\(\\) is incompatible with type int\\.$#', + 'identifier' => 'parameter.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-gd.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Image_Editor_GD\\:\\:_resize\\(\\) has invalid return type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-gd.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\$image of method WP_Image_Editor_GD\\:\\:_save\\(\\) has invalid type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-gd.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor_GD\\:\\:\\$image has unknown class GdImage as its type\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-gd.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Image_Editor_Imagick\\:\\:set_imagick_time_limit\\(\\) should return int\\|null but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:create_classic_menu_fallback\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:create_default_fallback\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:get_default_fallback_blocks\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:get_fallback_classic_menu\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:get_most_recently_created_nav_menu\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:get_most_recently_published_navigation\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:get_nav_menu_at_primary_location\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Navigation_Fallback\\:\\:get_nav_menu_with_primary_slug\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-navigation-fallback.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method get_error_code\\(\\) on object\\|false\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-oembed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$ID on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var above assignment does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 9, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$object_id on array\\|WP_Error\\|WP_Term\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-term-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON_Resolver\\:\\:inject_variations_from_block_style_variation_files\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON_Resolver\\:\\:inject_variations_from_block_styles_registry\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON_Resolver\\:\\:recursively_iterate_json\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON_Resolver\\:\\:remove_json_comments\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON_Resolver\\:\\:style_variation_has_scope\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON\\:\\:compute_spacing_sizes\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON\\:\\:get_block_nodes\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON\\:\\:merge_spacing_sizes\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON\\:\\:remove_indirect_properties\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON\\:\\:resolve_custom_css_format\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON\\:\\:unwrap_shared_block_style_variations\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Theme_JSON\\:\\:update_separator_declarations\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Binary operation "\\+" between array\\|int\\\\|int\\<1, max\\> and 1 results in an error\\.$#', + 'identifier' => 'binaryOp.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$term_id on string\\|WP_Customize_Setting\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$attr_title\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$db_id\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$description\\.$#', + 'identifier' => 'property.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$type\\.$#', + 'identifier' => 'property.notFound', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$type_label\\.$#', + 'identifier' => 'property.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to an undefined property WP_Post\\:\\:\\$url\\.$#', + 'identifier' => 'property.notFound', + 'count' => 5, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Font_Face_Resolver\\:\\:convert_font_face_properties\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/fonts/class-wp-font-face-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Font_Face_Resolver\\:\\:maybe_parse_name_from_comma_separated_list\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/fonts/class-wp-font-face-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Font_Face_Resolver\\:\\:parse_settings\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/fonts/class-wp-font-face-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Font_Face_Resolver\\:\\:to_kebab_case\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/fonts/class-wp-font-face-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unsafe call to private method WP_Font_Face_Resolver\\:\\:to_theme_file_uri\\(\\) through static\\:\\:\\.$#', + 'identifier' => 'staticClassAccess.privateMethod', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/fonts/class-wp-font-face-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @param references unknown parameter\\: \\$key$#', + 'identifier' => 'parameter.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @param references unknown parameter\\: \\$url$#', + 'identifier' => 'parameter.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @param references unknown parameter\\: \\$value$#', + 'identifier' => 'parameter.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/kses.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$link_id on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_imagecreatetruecolor\\(\\) has invalid return type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\$image of function is_gd_image\\(\\) has invalid type GdImage\\.$#', + 'identifier' => 'class.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$ID on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$plugins on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-block-directory-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method add_data\\(\\) on array\\|object\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-block-directory-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to private property WP_Block_Type\\:\\:\\$uses_context\\.$#', + 'identifier' => 'property.private', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-block-types-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Access to private property WP_Block_Type\\:\\:\\$variations\\.$#', + 'identifier' => 'property.private', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-block-types-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$auto_add on WP_Term\\|false\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-menus-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$download_link on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-plugins-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$language_packs on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-plugins-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method add_data\\(\\) on array\\|object\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-plugins-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot call method get_error_message\\(\\) on array\\|object\\.$#', + 'identifier' => 'method.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-plugins-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$post_content on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$post_excerpt on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$post_title on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$object_id on array\\|int\\|string\\|WP_Term\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$parent on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$template_name on array\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access property \\$term_id on array\\|object\\.$#', + 'identifier' => 'property.nonObject', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>" between int\\|string\\|WP_Term and 0 results in an error\\.$#', + 'identifier' => 'greater.invalid', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_list_users\\(\\) should return string\\|null but return statement is missing\\.$#', + 'identifier' => 'return.missing', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc tag @var does not specify variable name\\.$#', + 'identifier' => 'varTag.noVariable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/xmlrpc.php', +]; + +return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/phpstan/baseline/level-3.php b/tests/phpstan/baseline/level-3.php new file mode 100644 index 0000000000000..084ba5a666f27 --- /dev/null +++ b/tests/phpstan/baseline/level-3.php @@ -0,0 +1,803 @@ + '#^Method WP_Automatic_Updater\\:\\:update\\(\\) should return WP_Error\\|null but returns false\\.$#', + 'identifier' => 'return.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-automatic-updater.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access offset \'new_version\' on bool\\.$#', + 'identifier' => 'offsetAccess.nonOffsetAccessible', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Filesystem_Direct\\:\\:group\\(\\) should return string\\|false but returns int\\\\|int\\<1, max\\>\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-direct.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Filesystem_Direct\\:\\:owner\\(\\) should return string\\|false but returns int\\\\|int\\<1, max\\>\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-direct.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Filesystem_SSH2\\:\\:group\\(\\) should return string\\|false but returns int\\\\|int\\<1, max\\>\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ssh2.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Filesystem_SSH2\\:\\:owner\\(\\) should return string\\|false but returns int\\\\|int\\<1, max\\>\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ssh2.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Filesystem_SSH2\\:\\:\\$link \\(resource\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ssh2.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_status \\(bool\\) of method WP_Post_Comments_List_Table\\:\\:get_per_page\\(\\) should be compatible with parameter \\$comment_status \\(string\\) of method WP_Comments_List_Table\\:\\:get_per_page\\(\\)$#', + 'identifier' => 'method.childParameterType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-post-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Screen\\:\\:get_help_tab\\(\\) should return array but returns null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-screen.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Screen\\:\\:get_option\\(\\) should return string but returns null\\.$#', + 'identifier' => 'return.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-screen.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Screen\\:\\:get_screen_reader_text\\(\\) should return string but returns null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-screen.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Screen\\:\\:\\$columns \\(int\\) does not accept string\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-screen.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'preview\' does not exist on array\\{activate\\: non\\-falsy\\-string\\}\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-themes-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function WP_Filesystem\\(\\) should return bool\\|null but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_get_nav_menu_to_edit\\(\\) should return string\\|WP_Error\\|null but returns WP_Term\\|false\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function delete_plugins\\(\\) should return bool\\|WP_Error\\|null but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_create_category\\(\\) should return int\\|WP_Error but returns string\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function convert_to_screen\\(\\) should return WP_Screen but returns object\\{id\\: string, base\\: string\\}&stdClass\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function delete_theme\\(\\) should return bool\\|WP_Error\\|null but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Cannot access offset \'new_version\' on bool\\.$#', + 'identifier' => 'offsetAccess.nonOffsetAccessible', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/update-core.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Block_Template\\:\\:\\$author \\(int\\|null\\) does not accept string\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-template-utils.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function filter_block_kses\\(\\) should return array but returns ArrayAccess&WP_Block_Parser_Block\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/blocks.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'host\' does not exist on array\\{path\\: list\\\\|string\\|null\\}\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'port\' does not exist on array\\{path\\: list\\\\|string\\|null, host\\?\\: string\\}\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'query\' does not exist on array\\{path\\: list\\\\|string\\|null, host\\?\\: string\\}\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'query\' does not exist on array\\{path\\: list\\\\|string\\|null\\}\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'scheme\' does not exist on array\\{path\\: list\\\\|string\\|null, host\\?\\: string\\}\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_category_by_path\\(\\) should return array\\|WP_Error\\|WP_Term\\|null but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/category.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$args \\(stdClass\\) of method Walker_Nav_Menu\\:\\:end_lvl\\(\\) should be compatible with parameter \\$args \\(array\\) of method Walker\\:\\:end_lvl\\(\\)$#', + 'identifier' => 'method.childParameterType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-walker-nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$args \\(stdClass\\) of method Walker_Nav_Menu\\:\\:start_lvl\\(\\) should be compatible with parameter \\$args \\(array\\) of method Walker\\:\\:start_lvl\\(\\)$#', + 'identifier' => 'method.childParameterType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-walker-nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#4 \\$args \\(stdClass\\) of method Walker_Nav_Menu\\:\\:end_el\\(\\) should be compatible with parameter \\$args \\(array\\) of method Walker\\:\\:end_el\\(\\)$#', + 'identifier' => 'method.childParameterType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-walker-nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#4 \\$args \\(stdClass\\) of method Walker_Nav_Menu\\:\\:start_el\\(\\) should be compatible with parameter \\$args \\(array\\) of method Walker\\:\\:start_el\\(\\)$#', + 'identifier' => 'method.childParameterType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-walker-nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Walker_Nav_Menu\\:\\:\\$tree_type \\(string\\) does not accept default value of type array\\\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-walker-nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Block_Type\\:\\:__get\\(\\) should return array\\\\|string\\|void\\|null but returns array\\\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-type.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Block\\:\\:\\$inner_blocks \\(WP_Block_List\\) does not accept default value of type array\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Comment_Query\\:\\:\\$date_query \\(WP_Date_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-comment-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Comment_Query\\:\\:\\$meta_query \\(WP_Meta_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-comment-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Control\\:\\:\\$active_callback \\(callable\\(\\)\\: mixed\\) does not accept default value of type \'\'\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Control\\:\\:\\$settings \\(array\\) does not accept string\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Panel\\:\\:\\$active_callback \\(callable\\(\\)\\: mixed\\) does not accept default value of type \'\'\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-panel.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Panel\\:\\:\\$theme_supports \\(array\\\\) does not accept default value of type string\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-panel.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Section\\:\\:\\$active_callback \\(callable\\(\\)\\: mixed\\) does not accept default value of type \'\'\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-section.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Setting\\:\\:\\$default \\(string\\) does not accept stdClass\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Setting\\:\\:\\$sanitize_callback \\(callable\\(\\)\\: mixed\\) does not accept default value of type \'\'\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Setting\\:\\:\\$sanitize_js_callback \\(callable\\(\\)\\: mixed\\) does not accept default value of type \'\'\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Setting\\:\\:\\$validate_callback \\(callable\\(\\)\\: mixed\\) does not accept default value of type \'\'\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Dependencies\\:\\:\\$all_queued_deps \\(array\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-dependencies.php', +]; +$ignoreErrors[] = [ + 'message' => '#^WpOrg\\\\Requests\\\\Cookie\\\\Jar does not accept WpOrg\\\\Requests\\\\Cookie\\.$#', + 'identifier' => 'offsetAssign.valueType', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Image_Editor_Imagick\\:\\:set_imagick_time_limit\\(\\) should return int\\|null but returns float\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Image_Editor_Imagick\\:\\:write_image\\(\\) should return WP_Error\\|true but returns bool\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor_Imagick\\:\\:\\$image \\(Imagick\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Argument of an invalid type stdClass supplied for foreach, only iterables are supported\\.$#', + 'identifier' => 'foreach.nonIterable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-post-type.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Query\\:\\:setup_postdata\\(\\) should return true but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$date_query \\(WP_Date_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$meta_query \\(WP_Meta_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$queried_object_id \\(int\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Rewrite\\:\\:\\$rules \\(array\\\\) does not accept string\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Query\\:\\:\\$date_query \\(WP_Date_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-site-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Query\\:\\:\\$meta_query \\(WP_Meta_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-site-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Speculation_Rules\\:\\:jsonSerialize\\(\\) should return array\\\\> but returns array\\\\>\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-speculation-rules.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter &\\$query by\\-ref type of method WP_Tax_Query\\:\\:clean_query\\(\\) expects array, WP_Error given\\.$#', + 'identifier' => 'parameterByRef.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-tax-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter &\\$query by\\-ref type of method WP_Tax_Query\\:\\:transform_query\\(\\) expects array, WP_Error given\\.$#', + 'identifier' => 'parameterByRef.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-tax-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter &\\$query by\\-ref type of method WP_Tax_Query\\:\\:transform_query\\(\\) expects array, array\\\\|string given\\.$#', + 'identifier' => 'parameterByRef.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-tax-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Term_Query\\:\\:get_terms\\(\\) should return array\\\\|string but returns int\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-term-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Term_Query\\:\\:\\$meta_query \\(WP_Meta_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-term-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Term_Query\\:\\:\\$terms \\(array\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-term-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Term\\:\\:\\$term_group \\(int\\) does not accept default value of type string\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-term.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme_JSON_Resolver\\:\\:\\$blocks \\(WP_Theme_JSON\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme_JSON_Resolver\\:\\:\\$core \\(WP_Theme_JSON\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme_JSON_Resolver\\:\\:\\$i18n_schema \\(array\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme_JSON_Resolver\\:\\:\\$theme \\(WP_Theme_JSON\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme_JSON_Resolver\\:\\:\\$user \\(WP_Theme_JSON\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme_JSON_Resolver\\:\\:\\$user_custom_post_type_id \\(int\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json-resolver.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$block_template_folders \\(array\\\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$block_theme \\(bool\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$errors \\(WP_Error\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$headers_sanitized \\(array\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$name_translated \\(string\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$parent \\(WP_Theme\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$template \\(string\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$textdomain_loaded \\(bool\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$theme_root_uri \\(string\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme\\:\\:\\$cache_expiration \\(bool\\) does not accept default value of type int\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme\\:\\:\\$cache_expiration \\(bool\\) does not accept int\\\\|int\\<1, max\\>\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter &\\$matched_token_byte_length by\\-ref type of method WP_Token_Map\\:\\:read_token\\(\\) expects int\\|null, \\(float\\|int\\) given\\.$#', + 'identifier' => 'parameterByRef.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-token-map.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User_Query\\:\\:\\$meta_query \\(WP_Meta_Query\\) does not accept default value of type false\\.$#', + 'identifier' => 'property.defaultValue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User\\:\\:\\$roles \\(array\\\\) does not accept array\\\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method wp_xmlrpc_server\\:\\:wp_newTerm\\(\\) should return int\\|IXR_Error but returns string\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-xmlrpc-server.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property wpdb\\:\\:\\$col_info \\(array\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wpdb.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property wpdb\\:\\:\\$last_query \\(string\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wpdb.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc type array of property WP_Customize_Nav_Menu_Item_Setting\\:\\:\\$default is not covariant with PHPDoc type string of overridden property WP_Customize_Setting\\:\\:\\$default\\.$#', + 'identifier' => 'property.phpDocType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$post_author \\(string\\) does not accept int\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Return type \\(void\\|null\\) of method WP_Customize_Nav_Menu_Item_Setting\\:\\:update\\(\\) should be compatible with return type \\(bool\\) of method WP_Customize_Setting\\:\\:update\\(\\)$#', + 'identifier' => 'method.childReturnType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Customize_Nav_Menu_Setting\\:\\:filter_wp_get_nav_menu_object\\(\\) should return object\\|null but returns false\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc type array of property WP_Customize_Nav_Menu_Setting\\:\\:\\$default is not covariant with PHPDoc type string of overridden property WP_Customize_Setting\\:\\:\\$default\\.$#', + 'identifier' => 'property.phpDocType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Return type \\(void\\|null\\) of method WP_Customize_Nav_Menu_Setting\\:\\:update\\(\\) should be compatible with return type \\(bool\\) of method WP_Customize_Setting\\:\\:update\\(\\)$#', + 'identifier' => 'method.childReturnType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'basedir\' does not exist on string\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/fonts.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'baseurl\' does not exist on string\\.$#', + 'identifier' => 'offsetAccess.notFound', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/fonts.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_HTML_Decoder\\:\\:read_character_reference\\(\\) should return string\\|false but returns null\\.$#', + 'identifier' => 'return.type', + 'count' => 7, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-decoder.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_HTML_Tag_Processor\\:\\:\\$is_closing_tag \\(bool\\) does not accept null\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_dropdown_languages\\(\\) should return string but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/l10n.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Translation_Controller\\:\\:get_entries\\(\\) should return array\\ but returns array\\\\>\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/l10n/class-wp-translation-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Translation_File\\:\\:entries\\(\\) should return array\\\\> but returns array\\\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/l10n/class-wp-translation-file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Translation_File\\:\\:\\$entries \\(array\\\\) does not accept array\\\\>\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/l10n/class-wp-translation-file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_edit_post_link\\(\\) should return string\\|null but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_edit_term_link\\(\\) should return string\\|null but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_preview_post_link\\(\\) should return string\\|null but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function update_meta_cache\\(\\) should return array\\|false but returns bool\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/meta.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_update_nav_menu_item\\(\\) should return int\\|WP_Error but returns WP_Term\\|false\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_post_revision_title\\(\\) should return string\\|false but returns array\\{\\}\\|null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_post_revision_title_expanded\\(\\) should return string\\|false but returns array\\{\\}\\|null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_set_post_categories\\(\\) should return array\\|WP_Error\\|false but returns true\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_trash_post\\(\\) should return WP_Post\\|false\\|null but returns array\\{\\}\\|null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_untrash_post\\(\\) should return WP_Post\\|false\\|null but returns array\\{\\}\\|null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter &\\$result by\\-ref type of function _page_traverse_name\\(\\) expects array\\, array given\\.$#', + 'identifier' => 'parameterByRef.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc type false of property WP_REST_Attachments_Controller\\:\\:\\$allow_batch is not covariant with PHPDoc type array of overridden property WP_REST_Posts_Controller\\:\\:\\$allow_batch\\.$#', + 'identifier' => 'property.phpDocType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_REST_Autosaves_Controller\\:\\:get_item\\(\\) should return WP_Error\\|WP_Post but returns WP_REST_Response\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-autosaves-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_REST_Autosaves_Controller\\:\\:\\$revisions_controller \\(WP_REST_Revisions_Controller\\) does not accept WP_REST_Controller\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-autosaves-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_REST_Controller\\:\\:get_object_type\\(\\) should return string but returns null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc type false of property WP_REST_Font_Faces_Controller\\:\\:\\$allow_batch is not covariant with PHPDoc type array of overridden property WP_REST_Posts_Controller\\:\\:\\$allow_batch\\.$#', + 'identifier' => 'property.phpDocType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-font-faces-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^PHPDoc type false of property WP_REST_Font_Families_Controller\\:\\:\\$allow_batch is not covariant with PHPDoc type array of overridden property WP_REST_Posts_Controller\\:\\:\\$allow_batch\\.$#', + 'identifier' => 'property.phpDocType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-font-families-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$id \\(int\\) of method WP_REST_Global_Styles_Controller\\:\\:prepare_links\\(\\) should be compatible with parameter \\$post \\(WP_Post\\) of method WP_REST_Posts_Controller\\:\\:prepare_links\\(\\)$#', + 'identifier' => 'method.childParameterType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_REST_Template_Autosaves_Controller\\:\\:get_item\\(\\) should return WP_Error\\|WP_Post but returns WP_REST_Response\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_REST_Template_Autosaves_Controller\\:\\:\\$revisions_controller \\(WP_REST_Revisions_Controller\\) does not accept WP_REST_Controller\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$parent_template_id \\(string\\) of method WP_REST_Template_Revisions_Controller\\:\\:get_parent\\(\\) should be compatible with parameter \\$parent_post_id \\(int\\) of method WP_REST_Revisions_Controller\\:\\:get_parent\\(\\)$#', + 'identifier' => 'method.childParameterType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-template-revisions-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _wp_preview_post_thumbnail_filter\\(\\) should return array\\|null but returns string\\.$#', + 'identifier' => 'return.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_delete_post_revision\\(\\) should return WP_Post\\|false\\|null but returns array\\{\\}\\|null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_restore_post_revision\\(\\) should return int\\|false\\|null but returns array\\{\\}\\|null\\.$#', + 'identifier' => 'return.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Taxonomy\\:\\:\\$labels \\(stdClass\\) does not accept array\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _remove_theme_support\\(\\) should return bool but empty return statement found\\.$#', + 'identifier' => 'return.empty', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _wp_get_current_user\\(\\) should return WP_User but returns array\\|float\\|int\\|string\\|false\\|null\\.$#', + 'identifier' => 'return.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _wp_get_current_user\\(\\) should return WP_User but returns null\\.$#', + 'identifier' => 'return.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Widget_Media\\:\\:\\$l10n_defaults \\(array\\\\) does not accept array\\\\.$#', + 'identifier' => 'assign.propertyType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/widgets/class-wp-widget-media.php', +]; + +return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/phpstan/baseline/level-4.php b/tests/phpstan/baseline/level-4.php new file mode 100644 index 0000000000000..6732f779eb86b --- /dev/null +++ b/tests/phpstan/baseline/level-4.php @@ -0,0 +1,1193 @@ + '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/about.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/credits.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_array\\(\\) with array will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always true\\.$#', + 'identifier' => 'booleanNot.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-custom-image-header.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always true\\.$#', + 'identifier' => 'booleanNot.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-language-pack-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$post_type \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-checklist.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$post_status \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_string\\(\\) with bool will always evaluate to false\\.$#', + 'identifier' => 'function.impossibleType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Instanceof between Imagick and Imagick will always evaluate to true\\.$#', + 'identifier' => 'instanceof.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Ternary operator condition is always false\\.$#', + 'identifier' => 'ternary.alwaysFalse', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-debug-data.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset mixed on array\\{\\} in empty\\(\\) does not exist\\.$#', + 'identifier' => 'empty.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-internal-pointers.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static method WP_Internal_Pointers\\:\\:print_js\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-internal-pointers.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-internal-pointers.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Screen\\:\\:\\$post_type \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-screen.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of && is always true\\.$#', + 'identifier' => 'booleanAnd.rightAlwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always true\\.$#', + 'identifier' => 'booleanNot.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^While loop condition is always true\\.$#', + 'identifier' => 'while.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function method_exists\\(\\) with \'ParagonIE_Sodium…\' and \'runtime_speed_test\' will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function WP_Filesystem\\(\\) never returns null so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always true\\.$#', + 'identifier' => 'booleanNot.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_callable\\(\\) with \'exif_read_data\' will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_callable\\(\\) with \'iptcparse\' will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'created_timestamp\' on array\\{\\}\\|array\\{lossless\\?\\: mixed, bitrate\\?\\: int, bitrate_mode\\?\\: mixed, filesize\\?\\: int, mime_type\\?\\: mixed, length\\?\\: int, length_formatted\\?\\: mixed, width\\?\\: int, \\.\\.\\.\\} in empty\\(\\) does not exist\\.$#', + 'identifier' => 'empty.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^While loop condition is always true\\.$#', + 'identifier' => 'while.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_numeric\\(\\) with float\\|int\\|numeric\\-string will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function delete_plugins\\(\\) never returns null so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Taxonomy\\:\\:\\$meta_box_sanitize_cb \\(callable\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function delete_theme\\(\\) never returns null so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always false\\.$#', + 'identifier' => 'booleanNot.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^If condition is always false\\.$#', + 'identifier' => 'if.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Ternary operator condition is always true\\.$#', + 'identifier' => 'ternary.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/menu-header.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site\\:\\:\\$domain \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/my-sites.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \\(float\\|int\\) on array\\ in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/nav-menus.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network/sites.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\=\\=\\= between \'update\\-selected\' and mixed~\\(\'activate\'\\|\'activate\\-selected\'\\|\'deactivate\'\\|\'deactivate\\-selected\'\\|\'delete\\-selected\'\\|\'disable\\-auto\\-update\'\\|\'disable\\-auto\\-update\\-selected\'\\|\'enable\\-auto\\-update\'\\|\'enable\\-auto\\-update\\-selected\'\\|\'error_scrape\'\\|\'resume\'\\|\'update\\-selected\'\\) will always evaluate to false\\.$#', + 'identifier' => 'identical.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/plugins.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Left side of && is always true\\.$#', + 'identifier' => 'booleanAnd.leftAlwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/themes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Result of && is always false\\.$#', + 'identifier' => 'booleanAnd.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/themes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Block_Type\\:\\:\\$editor_style_handles \\(array\\\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset 1 on array\\{list\\, list\\\\} on left side of \\?\\? always exists and is not nullable\\.$#', + 'identifier' => 'nullCoalesce.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-supports/block-style-variations.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between null and string will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/block-supports/layout.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Result of \\|\\| is always true\\.$#', + 'identifier' => 'booleanOr.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-supports/position.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\=\\=\\= between \'sticky\' and \'sticky\' will always evaluate to true\\.$#', + 'identifier' => 'identical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-supports/position.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Left side of && is always true\\.$#', + 'identifier' => 'booleanAnd.leftAlwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-template-utils.php', +]; +$ignoreErrors[] = [ + 'message' => '#^While loop condition is always true\\.$#', + 'identifier' => 'while.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Left side of && is always true\\.$#', + 'identifier' => 'booleanAnd.leftAlwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'port\' on array\\{path\\: mixed, host\\?\\: mixed\\} in empty\\(\\) does not exist\\.$#', + 'identifier' => 'empty.offset', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'query\' on array\\{path\\: array\\|string\\|null\\} in empty\\(\\) does not exist\\.$#', + 'identifier' => 'empty.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset \'query\' on array\\{path\\: mixed, host\\?\\: mixed\\} in empty\\(\\) does not exist\\.$#', + 'identifier' => 'empty.offset', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/capabilities.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_string\\(\\) with string will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-bindings-registry.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Block_Bindings_Registry\\:\\:\\$supported_blocks is never read, only written\\.$#', + 'identifier' => 'property.onlyWritten', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-bindings-registry.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always true\\.$#', + 'identifier' => 'booleanNot.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-templates-registry.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always false\\.$#', + 'identifier' => 'booleanNot.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-comment-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Control\\:\\:\\$active_callback \\(callable\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Control\\:\\:\\$settings \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Manager\\:\\:\\$_changeset_post_id \\(int\\|false\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Manager\\:\\:\\$_changeset_uuid \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Manager\\:\\:\\$_post_values \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Manager\\:\\:\\$nav_menus \\(WP_Customize_Nav_Menus\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Manager\\:\\:\\$widgets \\(WP_Customize_Widgets\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of \\|\\| is always true\\.$#', + 'identifier' => 'booleanOr.rightAlwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Panel\\:\\:\\$active_callback \\(callable\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-panel.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Section\\:\\:\\$active_callback \\(callable\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-section.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Setting\\:\\:\\$_previewed_blog_id \\(int\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Widgets\\:\\:\\$selective_refreshable_widgets \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-widgets.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_array\\(\\) with mixed will always evaluate to false\\.$#', + 'identifier' => 'function.impossibleType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-date-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Dependencies\\:\\:\\$all_queued_deps \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-dependencies.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Dependency\\:\\:\\$ver \\(bool\\|string\\) on left side of \\?\\? is not nullable\\.$#', + 'identifier' => 'nullCoalesce.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-dependencies.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-dependencies.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Duotone\\:\\:\\$global_styles_block_names \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-duotone.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Duotone\\:\\:\\$global_styles_block_names is never written, only read\\.$#', + 'identifier' => 'property.onlyRead', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-duotone.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Duotone\\:\\:\\$global_styles_presets \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-duotone.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Duotone\\:\\:\\$global_styles_presets is never written, only read\\.$#', + 'identifier' => 'property.onlyRead', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-duotone.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-duotone.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Http_Cookie\\:\\:\\$domain \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-cookie.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Http_Cookie\\:\\:\\$name \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-cookie.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Http_Cookie\\:\\:\\$path \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-cookie.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Http_Cookie\\:\\:\\$port \\(int\\|string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-cookie.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Http_Cookie\\:\\:\\$value \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-cookie.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Result of \\|\\| is always false\\.$#', + 'identifier' => 'booleanOr.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-cookie.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Http\\:\\:_dispatch_request\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function method_exists\\(\\) with \'Imagick\' and \'setIteratorIndex\' will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_callable\\(\\) with \'exif_read_data\' will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$ID \\(int\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$queried_object_id \\(int\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$query \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$stopwords \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Recovery_Mode_Cookie_Service\\:\\:recovery_mode_hash\\(\\) never returns false so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-recovery-mode-cookie-service.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Rewrite\\:\\:\\$author_structure \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Rewrite\\:\\:\\$comment_feed_structure \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Rewrite\\:\\:\\$date_structure \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Rewrite\\:\\:\\$feed_structure \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Rewrite\\:\\:\\$page_structure \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Rewrite\\:\\:\\$search_structure \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between null and int\\|string will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 6, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-rewrite.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Dependency\\:\\:\\$args \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-scripts.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Dependency\\:\\:\\$translations_path \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-scripts.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Dependency\\:\\:\\$args \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-styles.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\<\\=" between 0 and int\\<0, max\\>\\|false is always true\\.$#', + 'identifier' => 'smallerOrEqual.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Theme\\:\\:parent\\(\\) never returns false so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$block_template_folders \\(array\\\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$block_theme \\(bool\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$headers_sanitized \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$name_translated \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$parent \\(WP_Theme\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$textdomain_loaded \\(bool\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme\\:\\:\\$theme_root_uri \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static method WP_Theme\\:\\:_check_headers_property_has_correct_type\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_Theme\\:\\:\\$persistently_cache \\(bool\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Static property WP_User\\:\\:\\$back_compat_keys \\(array\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of && is always true\\.$#', + 'identifier' => 'booleanAnd.rightAlwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-walker.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Widget\\:\\:\\$alt_option_name \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-widget.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\=\\=\\= between \'404\' and \'404\' will always evaluate to true\\.$#', + 'identifier' => 'identical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property wpdb\\:\\:\\$base_prefix \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wpdb.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of && is always false\\.$#', + 'identifier' => 'booleanAnd.rightAlwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wpdb.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Instanceof between mixed and ResourceBundle will always evaluate to false\\.$#', + 'identifier' => 'instanceof.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/compat.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Instanceof between mixed and SimpleXMLElement will always evaluate to false\\.$#', + 'identifier' => 'instanceof.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/compat.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Manager\\:\\:\\$nav_menus \\(WP_Customize_Nav_Menus\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Manager\\:\\:\\$nav_menus \\(WP_Customize_Nav_Menus\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-nav-menu-setting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Partial\\:\\:\\$render_callback \\(callable\\) in empty\\(\\) is not falsy\\.$#', + 'identifier' => 'empty.property', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-partial.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Partial\\:\\:\\$settings \\(array\\\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-partial.php', +]; +$ignoreErrors[] = [ + 'message' => '#^While loop condition is always false\\.$#', + 'identifier' => 'while.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/feed-rdf.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function method_exists\\(\\) with \'SimplePie_Cache\' and \'register\' will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/feed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>\\=" between int\\<2592000, 31535999\\> and 2592000 is always true\\.$#', + 'identifier' => 'greaterOrEqual.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>\\=" between int\\<31536000, max\\> and 31536000 is always true\\.$#', + 'identifier' => 'greaterOrEqual.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>\\=" between int\\<3600, 86399\\> and 3600 is always true\\.$#', + 'identifier' => 'greaterOrEqual.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>\\=" between int\\<60, 3599\\> and 60 is always true\\.$#', + 'identifier' => 'greaterOrEqual.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>\\=" between int\\<604800, 2591999\\> and 604800 is always true\\.$#', + 'identifier' => 'greaterOrEqual.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Comparison operation "\\>\\=" between int\\<86400, 604799\\> and 86400 is always true\\.$#', + 'identifier' => 'greaterOrEqual.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset 0 on array\\{0\\: non\\-empty\\-string, non_cdata_followed_by_cdata\\: \'\', 1\\: \'\', 2\\: \'\', cdata\\: \'\', 3\\: \'\', 4\\: \'\', non_cdata\\: string, \\.\\.\\.\\}\\|array\\{0\\: non\\-empty\\-string, non_cdata_followed_by_cdata\\: string, 1\\: string, 2\\: string, cdata\\: non\\-falsy\\-string, 3\\: non\\-falsy\\-string, 4\\: non\\-falsy\\-string\\} in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_callable\\(\\) with \'exif_imagetype\' will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset int\\<1, max\\> on non\\-empty\\-list\\ in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of && is always true\\.$#', + 'identifier' => 'booleanAnd.rightAlwaysTrue', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between \'Etc\' and \'Africa\'\\|\'America\'\\|\'Antarctica\'\\|\'Arctic\'\\|\'Asia\'\\|\'Atlantic\'\\|\'Australia\'\\|\'Europe\'\\|\'Indian\'\\|\'Pacific\' will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function single_cat_title\\(\\) never returns void so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/general-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function single_tag_title\\(\\) never returns void so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/general-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always true\\.$#', + 'identifier' => 'booleanNot.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/general-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-doctype-info.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_HTML_Tag_Processor\\:\\:skip_rawtext\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_HTML_Tag_Processor\\:\\:skip_script_data\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_HTML_Tag_Processor\\:\\:\\$skip_newline_at \\(int\\|null\\) is never assigned int so it can be removed from the property type\\.$#', + 'identifier' => 'property.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_HTML_Text_Replacement\\:\\:\\$text \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Result of && is always true\\.$#', + 'identifier' => 'booleanAnd.alwaysTrue', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between \'STATE_COMPLETE\' and \'STATE_READY\' will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between \'STATE_INCOMPLETE…\' and \'STATE_READY\' will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between \'STATE_MATCHED_TAG\' and \'STATE_READY\' will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\=\\=\\= between \'STATE_INCOMPLETE…\' and \'STATE_READY\' will always evaluate to false\\.$#', + 'identifier' => 'identical.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Unreachable statement \\- code above always terminates\\.$#', + 'identifier' => 'deadCode.unreachable', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/html-api/class-wp-html-tag-processor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_array\\(\\) with array will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_bind_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_class_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_context_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_each_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_interactive_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_router_region_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_style_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Interactivity_API\\:\\:data_wp_text_processor\\(\\) is unused\\.$#', + 'identifier' => 'method.unused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/interactivity-api/class-wp-interactivity-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of && is always true\\.$#', + 'identifier' => 'booleanAnd.rightAlwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/l10n.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$filter \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_string\\(\\) with bool will always evaluate to false\\.$#', + 'identifier' => 'function.impossibleType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/load.php', +]; +$ignoreErrors[] = [ + 'message' => '#^If condition is always false\\.$#', + 'identifier' => 'if.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/load.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of && is always true\\.$#', + 'identifier' => 'booleanAnd.rightAlwaysTrue', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-includes/load.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_imagecreatetruecolor\\(\\) never returns GdImage so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset 2 on array\\{string, non\\-empty\\-string, non\\-empty\\-string\\} in isset\\(\\) always exists and is not nullable\\.$#', + 'identifier' => 'isset.offset', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to function is_array\\(\\) with non\\-empty\\-array\\ will always evaluate to true\\.$#', + 'identifier' => 'function.alreadyNarrowedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/ms-functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always false\\.$#', + 'identifier' => 'booleanNot.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Term\\:\\:\\$term_id \\(int\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between 0 and int\\\\|int\\<1, max\\> will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between float\\|int\\|numeric\\-string and \'bottom\'\\|\'footer\'\\|\'header\'\\|\'main\'\\|\'menu\\-1\'\\|\'menu\\-2\'\\|\'navigation\'\\|\'primary\'\\|\'secondary\'\\|\'social\'\\|\'subsidiary\'\\|\'top\' will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Negated boolean expression is always true\\.$#', + 'identifier' => 'booleanNot.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/option.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between false and int will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\!\\=\\= between null and int will always evaluate to true\\.$#', + 'identifier' => 'notIdentical.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\=\\=\\= between 3000000000 and 2147483647 will always evaluate to false\\.$#', + 'identifier' => 'identical.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$filter \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Offset mixed on array\\{\\} in isset\\(\\) does not exist\\.$#', + 'identifier' => 'isset.offset', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Result of && is always false\\.$#', + 'identifier' => 'booleanAnd.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Result of && is always false\\.$#', + 'identifier' => 'booleanAnd.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^If condition is always false\\.$#', + 'identifier' => 'if.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$post_name \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-font-families-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post\\:\\:\\$post_title \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-font-families-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Post_Type\\:\\:\\$template \\(array\\\\) on left side of \\?\\? is not nullable\\.$#', + 'identifier' => 'nullCoalesce.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-post-types-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_REST_Template_Autosaves_Controller\\:\\:\\$parent_post_type is never read, only written\\.$#', + 'identifier' => 'property.onlyWritten', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Strict comparison using \\=\\=\\= between false and mixed will always evaluate to false\\.$#', + 'identifier' => 'identical.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function _set_preview\\(\\) never returns false so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$max_num_pages \\(int\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/sitemaps/providers/class-wp-sitemaps-posts.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function get_term_to_edit\\(\\) never returns int so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^While loop condition is always true\\.$#', + 'identifier' => 'while.alwaysTrue', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme-compat/embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function remove_theme_support\\(\\) never returns void so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site\\:\\:\\$domain \\(string\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User\\:\\:\\$ID \\(int\\) in isset\\(\\) is not nullable\\.$#', + 'identifier' => 'isset.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Right side of && is always true\\.$#', + 'identifier' => 'booleanAnd.rightAlwaysTrue', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^If condition is always false\\.$#', + 'identifier' => 'if.alwaysFalse', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-login.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Call to method WP_Theme\\:\\:load_textdomain\\(\\) on a separate line has no effect\\.$#', + 'identifier' => 'method.resultUnused', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-settings.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function validate_another_blog_signup\\(\\) never returns null so it can be removed from the return type\\.$#', + 'identifier' => 'return.unusedType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-signup.php', +]; + +return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/phpstan/baseline/level-5.php b/tests/phpstan/baseline/level-5.php new file mode 100644 index 0000000000000..ecbff95a81153 --- /dev/null +++ b/tests/phpstan/baseline/level-5.php @@ -0,0 +1,1763 @@ + '#^Parameter \\#1 \\$key of function remove_query_arg expects array\\\\|string, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-activate.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$subject of function str_replace expects array\\\\|string, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/admin-header.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_edit_post_link expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_post_status expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_the_title expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, bool given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/customize.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$position of function wp_comment_reply expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/edit-comments.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 5, + 'path' => __DIR__ . '/../../../src/wp-admin/edit-comments.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$screen of function do_meta_boxes expects string\\|WP_Screen, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/edit-form-advanced.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$screen of function do_meta_boxes expects string\\|WP_Screen, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/edit-form-comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$screen of function do_meta_boxes expects string\\|WP_Screen, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/edit-link-form.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$name of function submit_button expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/edit-tag-form.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_edit_post_link expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_post_type expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function add_action expects callable\\(\\)\\: mixed, \'print_emoji_styles\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/admin-filters.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$attachment of function wp_get_attachment_id3_keys expects WP_Post, stdClass given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function _wp_ajax_delete_comment_response expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$message of function wp_die expects string\\|WP_Error, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 111, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$message of function wp_die expects string\\|WP_Error, int\\<1, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 6, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$arr2 of function array_diff expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$compare_from of function wp_get_revision_ui_diff expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$compare_to of function wp_get_revision_ui_diff expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ajax-actions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$gmt of function current_time expects bool, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/bookmark.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$allowed_html of function wp_kses expects array\\\\|string, array\\\\|true\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-automatic-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-bulk-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_js expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-bulk-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function submit_button expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-custom-background.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, \\(float\\|int\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-custom-image-header.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function submit_button expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-custom-image-header.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$language_updates of method Language_Pack_Upgrader\\:\\:bulk_upgrade\\(\\) expects array\\, list\\\\|string\\|false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-language-pack-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-walker-nav-menu-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$str of function md5 expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-automatic-updater.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function get_comment_meta expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_post expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function post_password_required expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$post of function get_comment_class expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$min of function mktime expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ftpext.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#4 \\$mon of function mktime expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ftpext.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#5 \\$day of function mktime expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-ftpext.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function uasort expects callable\\(WP_Theme, WP_Theme\\)\\: int, array\\{\\$this\\(WP_MS_Themes_List_Table\\), \'_order_callback\'\\} given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-ms-themes-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-ms-users-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$number of function _nx expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugin-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugins-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$array of function implode expects array\\, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-posts-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-privacy-data-export-requests-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<0, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-privacy-data-export-requests-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-privacy-data-removal-requests-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<0, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-privacy-data-removal-requests-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$keys of function array_fill_keys expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-privacy-requests-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-privacy-requests-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<1, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-screen.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$version of function get_core_checksums expects string, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health-auto-updates.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$bytes of function size_format expects int\\|string, float\\|false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$allowed_html of function wp_kses expects array\\\\|string, array\\\\|true\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$allowed_html of function wp_kses expects array\\\\|string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$args of function WP_Filesystem expects array\\|false, true given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-upgrader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function _draft_or_post_title expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_the_permalink expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function post_password_required expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$name of function submit_button expects string, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/dashboard.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function add_filter expects callable\\(\\)\\: mixed, \'wxr_filter_postmeta\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/export.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$str of function md5 expects string, int\\<0, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$image of function is_gd_image expects GdImage\\|resource\\|false, WP_Image_Editor given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$width of function wp_imagecreatetruecolor expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$height of function wp_imagecreatetruecolor expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#5 \\$src_x of function imagecopy expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#6 \\$src_y of function imagecopy expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#7 \\$src_w of function imagecopy expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#8 \\$src_h of function imagecopy expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$array \\(non\\-empty\\-list\\\\) of array_values is already a list, call has no effect\\.$#', + 'identifier' => 'arrayValues.list', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/image.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post_id of function wp_delete_attachment expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/import.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$number of function number_format_i18n expects float, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post_id of function get_media_items expects int, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$result of function wp_parse_str expects array, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/meta-boxes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 8, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/misc.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<0, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/misc.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<1, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/misc.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ms.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$value of function update_blog_status expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/ms.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$arr2 of function array_intersect expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$tags of function wp_generate_tag_cloud expects array\\, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$name of function submit_button expects string, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$number of function _nx expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$allowed_html of function wp_kses expects array\\\\|string, array\\\\|true\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/plugin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$fallback_title of function sanitize_title expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$user_id of function get_the_author_meta expects int\\|false, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/revision.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$str of function md5 expects string, int\\<1, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/schema.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$multiplier of function str_repeat expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$title of function add_meta_box expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$callback of function add_meta_box expects callable\\(\\)\\: mixed, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$update of method Language_Pack_Upgrader\\:\\:upgrade\\(\\) expects string\\|false, stdClass given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/translation-install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/update.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$timestamp of function wp_schedule_event expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/upgrade.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$deprecated of function add_option expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/upgrade.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user of function wp_get_user_contact_methods expects WP_User\\|null, stdClass given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#4 \\$is_public of function wp_install expects bool, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/install.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 5, + 'path' => __DIR__ . '/../../../src/wp-admin/nav-menus.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$menu_data of function wp_save_nav_menu_items expects array\\, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/nav-menus.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$message of function wp_die expects string\\|WP_Error, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$network_id of function can_edit_network expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-info.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-info.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$network_id of function can_edit_network expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-settings.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-settings.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$network_id of function can_edit_network expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-themes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-themes.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$network_id of function can_edit_network expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-users.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-admin/network/site-users.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/network/sites.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<2, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/options-discussion.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, bool given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/options-general.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<0, 6\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/options-general.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$arr2 of function array_diff expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/plugins.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function array_filter expects \\(callable\\(mixed\\)\\: bool\\)\\|null, \'validate_file\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/plugins.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$newvalue of function ini_set expects string, true given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/plugins.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$newvalue of function ini_set expects string, true given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/update.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/user-edit.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-admin/users.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$userid of function count_user_posts expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/author-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function add_action expects callable\\(\\)\\: mixed, \'print_emoji_styles\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$separator of function explode expects string, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/block-supports/layout.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$block of function filter_block_kses expects WP_Block_Parser_Block, array given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/blocks.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#4 \\$block_context of function filter_block_kses_value expects array\\|null, WP_Block_Parser_Block given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/blocks.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$arr2 of function array_intersect expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function preg_replace_callback expects callable\\(array\\\\)\\: string, \'lowercase_octets\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/canonical.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_post expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/capabilities.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user_id of function get_userdata expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/capabilities.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$blog_id of function get_home_url expects int\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-admin-bar.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function add_action expects callable\\(\\)\\: mixed, \'wp_admin_bar_header\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-admin-bar.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$name of class WP_Block_Parser_Block constructor expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-parser.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$child_id of method WP_Comment\\:\\:get_child\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-comment-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$ids of function _prime_post_caches expects array\\, list\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-comment-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_post expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$ajax_message of method WP_Customize_Manager\\:\\:wp_die\\(\\) expects string\\|WP_Error, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 6, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$arr1 of function array_diff expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$message of function wp_die expects string\\|WP_Error, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$month of function wp_checkdate expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$day of function wp_checkdate expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$year of function wp_checkdate expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-manager.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$message of function wp_die expects string\\|WP_Error, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-nav-menus.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$message of function wp_die expects string\\|WP_Error, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-widgets.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_html expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-date-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$parent_query of method WP_Date_Query\\:\\:get_sql_for_clause\\(\\) expects array, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-date-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$timestamp of function gmdate expects int, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-date-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_Date_Query\\:\\:build_value\\(\\) expects array\\|string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-date-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_Date_Query\\:\\:build_value\\(\\) expects array\\|string, int\\|null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-date-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$value of static method WP_Duotone\\:\\:colord_parse_hue\\(\\) expects float, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-duotone.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$priority of function _wp_filter_build_unique_id expects int, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-hook.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$value of function curl_setopt expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-curl.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$mode of function stream_set_blocking expects bool, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-http-streams.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of method WP_Image_Editor_GD\\:\\:make_image\\(\\) expects callable\\(\\)\\: mixed, \'imageavif\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-gd.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$limit of static method Imagick\\:\\:setResourceLimit\\(\\) expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method Imagick\\:\\:setOption\\(\\) expects string, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method Imagick\\:\\:setOption\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method Imagick\\:\\:setOption\\(\\) expects string, true given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor-imagick.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user_id of function get_userdata expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$arr2 of function array_intersect expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$array of function implode expects array\\, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$new_blog_id of function switch_to_blog expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-site.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, array given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-styles.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$array of function implode expects array\\, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-term-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$metadata of method WP_Theme_JSON\\:\\:get_feature_declarations_for_node\\(\\) expects object, array given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$styles of static method WP_Theme_JSON\\:\\:compute_style_properties\\(\\) expects array, object given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme-json.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$data of method WP_Theme\\:\\:cache_add\\(\\) expects array\\|string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$translate of method WP_Theme\\:\\:display\\(\\) expects bool, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$translate of method WP_Theme\\:\\:markup_header\\(\\) expects string, bool given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#4 \\$expire of function wp_cache_add expects int, bool given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$str of function strtoupper expects string, bool given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-token-map.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$array of function implode expects array\\, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 6, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$level of method WP_User\\:\\:translate_level_to_cap\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$number of method WP_Widget\\:\\:_set\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-widget.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_the_title expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-xmlrpc-server.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$term_id of method wp_xmlrpc_server\\:\\:get_term_custom_fields\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-xmlrpc-server.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user_id of function get_userdata expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-xmlrpc-server.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$arr2 of function array_intersect expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function get_page_of_comment expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_permalink expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function post_password_required expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user_id of function get_userdata expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/comment-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment of function get_comment_link expects int\\|WP_Comment\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function add_comment_meta expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 5, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function delete_comment_meta expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 8, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function get_comment_meta expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function get_comment_text expects int\\|WP_Comment, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function get_page_of_comment expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$content of function pingback expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$ids of function clean_comment_cache expects array\\|int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post_id of function wp_update_comment_count expects int\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$object_ids of function update_meta_cache expects array\\\\|string, list\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/comment.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$gmt_time of function spawn_cron expects int, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/cron.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$container_context of method WP_Customize_Partial\\:\\:render\\(\\) expects array, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-selective-refresh.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function add_action expects callable\\(\\)\\: mixed, \'print_embed_styles\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/default-filters.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function add_action expects callable\\(\\)\\: mixed, \'print_emoji_styles\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/default-filters.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function add_action expects callable\\(\\)\\: mixed, \'the_block_template…\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/default-filters.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$response of method WP_REST_Server\\:\\:response_to_data\\(\\) expects WP_REST_Response, WP_HTTP_Response given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user_id of function get_userdata expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post_id of function get_post_comments_feed_link expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/feed-atom-comments.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post_id of function get_post_comments_feed_link expects int, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/feed-rss2.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_the_guid expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/feed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$number of function zeroise expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function preg_replace_callback expects callable\\(array\\\\)\\: string, \'_links_add_base\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function preg_replace_callback expects callable\\(array\\\\)\\: string, \'_links_add_target\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/formatting.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$prefix of function uniqid expects string, int\\<0, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$fallback_url of function wp_validate_redirect expects string, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$number of function _n expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#4 \\$mon of function mktime expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#5 \\$day of function mktime expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#6 \\$year of function mktime expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, float given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/general-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$replace of function str_replace expects array\\\\|string, int\\<1, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/general-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$replace of function str_replace expects array\\\\|string, int\\\\|int\\<2, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/general-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$url of function wp_admin_css_color expects string, false given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/general-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$blog_id of function get_admin_url expects int\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user_id of function get_userdata expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$replace of function str_replace expects array\\\\|string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/link-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$str of function md5 expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/load.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$newvalue of function ini_set expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-includes/load.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$subject of function str_replace expects array\\\\|string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/load.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int\\<1, 9\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_html expects string, int\\<1, 9\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$array of function array_unique expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#5 \\$text of function wp_get_attachment_link expects string\\|false, bool given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/media.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$value of function update_blog_status expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/ms-functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$network_id of static method WP_Network\\:\\:get_instance\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/ms-load.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$month of function wp_checkdate expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/ms-site.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$day of function wp_checkdate expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/ms-site.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$object_id of function delete_metadata expects int, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/ms-site.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$year of function wp_checkdate expects int, \\(string\\|false\\) given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/ms-site.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post_id of function wp_delete_post expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/nav-menu.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of function setcookie expects string, int\\<1, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/option.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$engine of class Text_Diff constructor expects string, list\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$message of function wp_die expects string\\|WP_Error, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_permalink expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 4, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_post expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user of function user_can expects int\\|WP_User, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$user_id of function get_userdata expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/pluggable.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$url of function user_trailingslashit expects string, int\\\\|int\\<2, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$fallback of function sanitize_html_class expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$replace of function str_replace expects array\\\\|string, int\\<1, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$user_id of function get_the_author_meta expects int\\|false, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post-template.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$keys of function array_fill_keys expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$string of function strlen expects string, int\\<2, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$arr2 of function array_diff expects an array of values castable to string, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$array of function implode expects array\\, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$object_id of function delete_metadata expects int, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/post.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$data_object of method WP_REST_Controller\\:\\:update_additional_fields_for_object\\(\\) expects object, array given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-application-passwords-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function get_comment_type expects int\\|WP_Comment, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function wp_delete_comment expects int\\|WP_Comment, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$comment_id of function wp_trash_comment expects int\\|WP_Comment, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$object_id of method WP_REST_Meta_Fields\\:\\:get_value\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_post expects int\\|WP_Post\\|null, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 3, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$comment_id of method WP_REST_Comments_Controller\\:\\:handle_status_param\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$object_id of method WP_REST_Meta_Fields\\:\\:update_value\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, array\\|int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-font-collections-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int\\<0, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-font-collections-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-revisions-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-revisions-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-search-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$args of function get_taxonomies expects array, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-taxonomies-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$id of function get_block_template expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$id of method WP_REST_Templates_Controller\\:\\:prepare_links\\(\\) expects int, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-terms-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-themes-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int\\<0, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-themes-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$value of method WP_HTTP_Response\\:\\:header\\(\\) expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$arr1 of function array_diff expects an array of values castable to string, list\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/search/class-wp-rest-post-search-handler.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$array_arg of function usort contains unresolvable type\\.$#', + 'identifier' => 'argument.unresolvableType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/script-loader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$callback of function usort contains unresolvable type\\.$#', + 'identifier' => 'argument.unresolvableType', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/script-loader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$src of method WP_Dependencies\\:\\:add\\(\\) expects string\\|false, true given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/script-loader.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$terms of function wp_update_term_count expects array\\|int, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$array of function implode expects array\\, array\\ given\\.$#', + 'identifier' => 'argument.type', + 'count' => 2, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$fallback_title of function sanitize_title expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$fallback_title of function sanitize_title expects string, int\\|WP_Error given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#2 \\$taxonomy of function wp_update_term_count expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/taxonomy.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$replacement of function _deprecated_file expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme-compat/comments.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$replacement of function _deprecated_file expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme-compat/footer.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$replacement of function _deprecated_file expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme-compat/header.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$replacement of function _deprecated_file expects string, null given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme-compat/sidebar.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$string of function strlen expects string, int\\<2, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/theme-templates.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$str of function mb_strlen expects string, int\\<2, max\\> given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/user.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$control_callback of function wp_register_widget_control expects callable\\(\\)\\: mixed, \'\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/widgets.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#3 \\$output_callback of function wp_register_sidebar_widget expects callable\\(\\)\\: mixed, \'\' given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/widgets.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_attr expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/widgets/class-wp-nav-menu-widget.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$post of function get_the_title expects int\\|WP_Post, string given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/widgets/class-wp-widget-recent-comments.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Parameter \\#1 \\$text of function esc_html expects string, int given\\.$#', + 'identifier' => 'argument.type', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-mail.php', +]; + +return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/phpstan/baseline/level-6.php b/tests/phpstan/baseline/level-6.php new file mode 100644 index 0000000000000..a1a0f3d668b71 --- /dev/null +++ b/tests/phpstan/baseline/level-6.php @@ -0,0 +1,641 @@ + '#^Property Automatic_Upgrader_Skin\\:\\:\\$messages has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-automatic-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Language_Pack_Upgrader_Skin\\:\\:\\$display_footer_actions has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-language-pack-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Language_Pack_Upgrader_Skin\\:\\:\\$language_update has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-language-pack-upgrader-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Plugin_Installer_Skin\\:\\:\\$api has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Plugin_Installer_Skin\\:\\:\\$is_downgrading has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Plugin_Installer_Skin\\:\\:\\$overwrite has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Plugin_Installer_Skin\\:\\:\\$type has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Plugin_Installer_Skin\\:\\:\\$url has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-plugin-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Theme_Installer_Skin\\:\\:\\$api has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Theme_Installer_Skin\\:\\:\\$is_downgrading has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Theme_Installer_Skin\\:\\:\\$overwrite has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Theme_Installer_Skin\\:\\:\\$type has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property Theme_Installer_Skin\\:\\:\\$url has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-theme-installer-skin.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Comments_List_Table\\:\\:\\$checkbox has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Comments_List_Table\\:\\:\\$extra_items has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Comments_List_Table\\:\\:\\$pending_count has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Comments_List_Table\\:\\:\\$user_can has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-comments-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Filesystem_Base\\:\\:\\$options has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-filesystem-base.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_List_Table_Compat\\:\\:\\$_columns has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-list-table-compat.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_List_Table_Compat\\:\\:\\$_screen has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-list-table-compat.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Media_List_Table\\:\\:\\$is_trash has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-media-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_MS_Themes_List_Table\\:\\:\\$has_items has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-ms-themes-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_MS_Themes_List_Table\\:\\:\\$is_site_themes has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-ms-themes-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_MS_Themes_List_Table\\:\\:\\$site_id has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-ms-themes-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Plugin_Install_List_Table\\:\\:\\$error has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugin-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Plugin_Install_List_Table\\:\\:\\$groups has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugin-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Plugin_Install_List_Table\\:\\:\\$order has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugin-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Plugin_Install_List_Table\\:\\:\\$orderby has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-plugin-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Posts_List_Table\\:\\:\\$is_trash has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-posts-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Privacy_Policy_Content\\:\\:\\$policy_content has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-privacy-policy-content.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$crons has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$instance has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$is_acceptable_mysql_version has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$is_mariadb has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$is_recommended_mysql_version has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$last_late_cron has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$last_missed_cron has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$mariadb_recommended_version has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$mysql_recommended_version has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$mysql_required_version has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$mysql_server_version has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$php_memory_limit has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Site_Health\\:\\:\\$schedules has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-site-health.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Terms_List_Table\\:\\:\\$callback_args has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-terms-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Terms_List_Table\\:\\:\\$level has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-terms-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Theme_Install_List_Table\\:\\:\\$features has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-theme-install-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Themes_List_Table\\:\\:\\$features has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-themes-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Themes_List_Table\\:\\:\\$search_terms has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/class-wp-themes-list-table.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_handle_upload_error\\(\\) has parameter \\$file with no type specified\\.$#', + 'identifier' => 'missingType.parameter', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function wp_handle_upload_error\\(\\) has parameter \\$message with no type specified\\.$#', + 'identifier' => 'missingType.parameter', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-admin/includes/file.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Admin_Bar\\:\\:\\$bound has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-admin-bar.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Admin_Bar\\:\\:\\$nodes has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-admin-bar.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Admin_Bar\\:\\:\\$user has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-admin-bar.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Class WP_Block_List implements generic interface ArrayAccess but does not specify its types\\: TKey, TValue$#', + 'identifier' => 'missingType.generics', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-list.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Class WP_Block_List implements generic interface Iterator but does not specify its types\\: TKey, TValue$#', + 'identifier' => 'missingType.generics', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-list.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Block_Templates_Registry\\:\\:\\$registered_templates has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block-templates-registry.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Widgets\\:\\:\\$_is_capturing_option_updates has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-customize-widgets.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$baseurl has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$drag_drop_upload has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$editor_buttons_css has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$ext_plugins has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$first_init has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$has_medialib has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$has_quicktags has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$has_tinymce has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$link_dialog_printed has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$mce_locale has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$mce_settings has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$plugins has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$qt_buttons has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$qt_settings has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$this_quicktags has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$this_tinymce has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$tinymce_scripts_printed has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property _WP_Editors\\:\\:\\$translation has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Embed\\:\\:\\$handlers has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Embed\\:\\:\\$last_attr has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Embed\\:\\:\\$last_url has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Embed\\:\\:\\$linkifunknown has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Embed\\:\\:\\$post_ID has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Embed\\:\\:\\$usecache has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-embed.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Feed_Cache_Transient\\:\\:__construct\\(\\) has parameter \\$type with no type specified\\.$#', + 'identifier' => 'missingType.parameter', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-feed-cache-transient.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Class WP_Hook implements generic interface ArrayAccess but does not specify its types\\: TKey, TValue$#', + 'identifier' => 'missingType.generics', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-hook.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Class WP_Hook implements generic interface Iterator but does not specify its types\\: TKey, TValue$#', + 'identifier' => 'missingType.generics', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-hook.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor\\:\\:\\$default_mime_type has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor\\:\\:\\$default_quality has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor\\:\\:\\$file has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor\\:\\:\\$mime_type has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor\\:\\:\\$output_mime_type has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor\\:\\:\\$quality has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Image_Editor\\:\\:\\$size has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-image-editor.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$compat_fields has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Query\\:\\:\\$compat_methods has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Class WP_Theme implements generic interface ArrayAccess but does not specify its types\\: TKey, TValue$#', + 'identifier' => 'missingType.generics', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Method WP_Theme\\:\\:_check_headers_property_has_correct_type\\(\\) has parameter \\$headers with no type specified\\.$#', + 'identifier' => 'missingType.parameter', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-theme.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User_Query\\:\\:\\$compat_fields has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User_Query\\:\\:\\$query_fields has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User_Query\\:\\:\\$query_from has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User_Query\\:\\:\\$query_limit has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User_Query\\:\\:\\$query_orderby has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_User_Query\\:\\:\\$query_where has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/class-wp-user-query.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Upload_Control\\:\\:\\$context has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-upload-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Upload_Control\\:\\:\\$extensions has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-upload-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Property WP_Customize_Upload_Control\\:\\:\\$removed has no type specified\\.$#', + 'identifier' => 'missingType.property', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/customize/class-wp-customize-upload-control.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Function add_query_arg\\(\\) has parameter \\$args with no type specified\\.$#', + 'identifier' => 'missingType.parameter', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/functions.php', +]; +$ignoreErrors[] = [ + 'message' => '#^Class WP_REST_Request implements generic interface ArrayAccess but does not specify its types\\: TKey, TValue$#', + 'identifier' => 'missingType.generics', + 'count' => 1, + 'path' => __DIR__ . '/../../../src/wp-includes/rest-api/class-wp-rest-request.php', +]; + +return ['parameters' => ['ignoreErrors' => $ignoreErrors]]; diff --git a/tests/phpstan/bootstrap.php b/tests/phpstan/bootstrap.php new file mode 100644 index 0000000000000..bf91cbe7e51a3 --- /dev/null +++ b/tests/phpstan/bootstrap.php @@ -0,0 +1,96 @@ +