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

Narrow property type hints #258

Merged
merged 7 commits into from
Jun 22, 2022
Merged

Narrow property type hints #258

merged 7 commits into from
Jun 22, 2022

Conversation

spawnia
Copy link
Collaborator

@spawnia spawnia commented Mar 21, 2022

  • Added or updated tests
  • Added or updated the README.md
  • Detailed changes in the CHANGELOG.md unreleased section

Related Issue/Intent

I noticed that static analysis in my project failed, due to using $key and $description as string.

Changes

Narrows the property type hints of enum classes.

I also added PHPStan analysis for this project itself to ensure the changes I made are correct and fixed some static analysis errors.

Breaking changes

None, since we are not using strong types for the properties.

@spawnia spawnia added the bug label Mar 21, 2022
@spawnia spawnia requested a review from BenSampo March 21, 2022 11:36
@spawnia
Copy link
Collaborator Author

spawnia commented Jun 20, 2022

@BenSampo Would you like to review this, or can I just merge trivial changes like this?

@BenSampo
Copy link
Owner

@spawnia Sorry, haven't had a chance to review yet. If you're happy with it then I am - please go ahead and merge. Same for any future non breaking changes.

@spawnia spawnia merged commit aee407f into master Jun 22, 2022
@spawnia spawnia deleted the phpstan branch June 22, 2022 08:29
@spawnia
Copy link
Collaborator Author

spawnia commented Jun 22, 2022

Thanks @BenSampo, will do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants