Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: [PHPStan] bad return type for WPHelpers::get_supported_post_types() #94

Conversation

justlevine
Copy link
Contributor

This PR fixes WPHelpers::get_supported_post_types(), so it
a) Correctly hints as an array of WP_Post_Type objects.
b) Doesn't return void.

The method signature has changed to include a PHP return type, to help prevent future regressions.

Caught by PHPStan level 2.

@justlevine justlevine requested a review from a team as a code owner May 19, 2023 04:37
@changeset-bot
Copy link

changeset-bot bot commented May 19, 2023

🦋 Changeset detected

Latest commit: 9dcfcf2

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@wpengine/wp-graphql-content-blocks Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@theodesp theodesp merged commit addf06f into wpengine:main May 22, 2023
@justlevine justlevine deleted the fix/bad-return-type-get_supported_post_types branch May 22, 2023 10:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants