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

Add more specific psalm type for QueryFunctionsInterface::count() result #810

Merged
merged 1 commit into from
Feb 14, 2024

Conversation

vjik
Copy link
Member

@vjik vjik commented Feb 13, 2024

Q A
Is bugfix?
New feature?
Breaks BC?

Copy link

what-the-diff bot commented Feb 13, 2024

PR Summary

  • Enhanced function definition in QueryFunctionsInterface class
    The 'count()' function in the QueryFunctionsInterface class now has a more specific type associated with it. This promotes increased accuracy during code execution.

  • Added a code annotation in Query class
    An annotation - '@psalm-var non-negative-int|string' - has been added in the 'count()' function located in the Query class. Annotations help developers better understand the intended function use and output expectation. In this case, it indicates that the function should return a non-negative integer or a string.

Copy link

codecov bot commented Feb 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (4a08ca3) 99.64% compared to head (134d399) 99.55%.
Report is 2 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #810      +/-   ##
============================================
- Coverage     99.64%   99.55%   -0.10%     
- Complexity     1270     1277       +7     
============================================
  Files            63       63              
  Lines          3106     3120      +14     
============================================
+ Hits           3095     3106      +11     
- Misses           11       14       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@vjik vjik requested a review from a team February 13, 2024 18:51
@vjik vjik added the status:code review The pull request needs review. label Feb 13, 2024
@vjik vjik merged commit 03dc434 into master Feb 14, 2024
169 of 171 checks passed
@vjik vjik deleted the psalm-count branch February 14, 2024 07:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:code review The pull request needs review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants