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

Remove usage middleware dispatcher in Route, Group and MatchingResult #210

Closed
wants to merge 5 commits into from

Conversation

vjik
Copy link
Member

@vjik vjik commented Jun 7, 2023

Q A
Is bugfix?
New feature?
Breaks BC? ✔️
Fixed issues -

@what-the-diff
Copy link

what-the-diff bot commented Jun 7, 2023

PR Summary

  • Removed middleware dispatcher usage
    Simplified code by removing middleware dispatcher usage in Route, Group, and MatchingResult.

  • Improved RouteCollectorInterface
    Replaced two methods with a single method, addRoute(), to streamline the interface.

  • Support for psr/http-message version ^2.0
    Added support for the latest psr/http-message version, reducing the dependency on the yiisoft/psr7 library.

  • Removed SimpleContainer
    Cleaned up code by removing the unnecessary SimpleContainer.

  • Updated TestCase class and tests
    Enhanced the TestCase class with the getDispatcher() method and updated related tests to use the new Dispatcher instance.

@codecov
Copy link

codecov bot commented Jun 7, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: -0.22 ⚠️

Comparison is base (ee824c0) 97.57% compared to head (5783c3d) 97.36%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #210      +/-   ##
============================================
- Coverage     97.57%   97.36%   -0.22%     
+ Complexity      139      125      -14     
============================================
  Files             9        9              
  Lines           413      379      -34     
============================================
- Hits            403      369      -34     
  Misses           10       10              
Impacted Files Coverage Δ
src/MatchingResult.php 100.00% <ø> (ø)
src/Group.php 100.00% <100.00%> (ø)
src/Middleware/Router.php 100.00% <100.00%> (ø)
src/Route.php 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@vjik vjik requested a review from a team June 7, 2023 11:58
@vjik vjik added the status:code review The pull request needs review. label Jun 7, 2023
@xepozz
Copy link
Member

xepozz commented Jun 8, 2023

Already exists in #194 and #196

@vjik
Copy link
Member Author

vjik commented Jun 9, 2023

Already exists in #194 and #196

I missed it. May be make it in this PR? It will be easier to add attributes.

CHANGELOG.md Outdated Show resolved Hide resolved
Co-authored-by: Alexander Makarov <[email protected]>
@vjik
Copy link
Member Author

vjik commented Jun 9, 2023

Closed in favor #196

@vjik vjik closed this Jun 9, 2023
@vjik vjik deleted the remove-dispatcher-from-routes branch June 9, 2023 17:14
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.

4 participants