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

[5.2] Router: Check directly for RouterInterface #43119

Merged
merged 1 commit into from
Mar 22, 2024

Conversation

Hackwar
Copy link
Member

@Hackwar Hackwar commented Mar 22, 2024

Summary of Changes

I have no idea why I took this complicated approach of using Reflection to see if the given object implements the RouterInterface. This PR changes the code to be simpler and to just use the instanceof operator.

Testing Instructions

Codereview

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

@Fedik
Copy link
Member

Fedik commented Mar 22, 2024

I have tested this item ✅ successfully on 062d2f9


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43119.

@Hackwar
Copy link
Member Author

Hackwar commented Mar 22, 2024

For 6.0 we should enforce the interface by typehinting the input vars properly.

@wilsonge wilsonge merged commit c23fdab into joomla:5.2-dev Mar 22, 2024
3 of 4 checks passed
@wilsonge
Copy link
Contributor

Trivial change so merging with a single good test + my code review

@wilsonge wilsonge added this to the Joomla! 5.2.0 milestone Mar 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants