PR-6.1-dev Pending

User tests: Successful: Unsuccessful:

avatar jayakrishna200
jayakrishna200
26 Feb 2026

Pull Request resolves #.

  • I read the Generative AI policy and my contribution is either not created with the help of AI or is compatible with the policy and GNU/GPL 2 or later.

Summary of Changes

Fixed type inconsistencies in the getCategoryRoute() method of the Content component's RouteHelper class:

  1. Updated parameter type documentation: Changed $language parameter type from integer to string|null in the docblock to match the actual parameter usage and default value
  2. Corrected default parameter value: Changed default value of $language parameter from 0 (integer) to null for consistency with type hints
  3. Fixed return docblock: Corrected return description from "The article route" to "The category route" (copy-paste error)

These changes align the getCategoryRoute() method signature with the similar getArticleRoute() method and improve code consistency.

Testing Instructions

  1. Navigate to the Content component helper file
  2. Verify that the method signature now correctly reflects the parameter type
  3. Check that existing calls to getCategoryRoute() continue to work as expected
  4. No breaking changes - the method behavior remains the same

Actual result BEFORE applying this Pull Request

The getCategoryRoute() method had type inconsistencies:

  • Docblock declared $language as integer but default was 0
  • The method actually uses $language as a string (compared to '*')
  • Return docblock incorrectly said "article route"

Expected result AFTER applying this Pull Request

The getCategoryRoute() method now has consistent type hints:

  • Docblock correctly declares $language as string|null
  • Default parameter is null
  • Return docblock correctly identifies it returns "category route"
  • Code is consistent with the getArticleRoute() method pattern

Link to documentations

Please select:

  • Documentation link for guide.joomla.org: Not applicable

  • No documentation changes for guide.joomla.org needed

  • Pull Request link for manual.joomla.org: Not applicable

  • No documentation changes for manual.joomla.org needed

avatar jayakrishna200 jayakrishna200 - open - 26 Feb 2026
avatar jayakrishna200 jayakrishna200 - change - 26 Feb 2026
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 26 Feb 2026
Category Repository Administration com_admin SQL
avatar brianteeman
brianteeman - comment - 26 Feb 2026

You have created a pull request for Joomla 6.1 but you have submitted it to the Joomla 5.4 branch

avatar jayakrishna200
jayakrishna200 - comment - 26 Feb 2026

You have created a pull request for Joomla 6.1 but you have submitted it to the Joomla 5.4 branch

I was changed base to 6.1-dev, please let me still I need to do anything else.

avatar richard67 richard67 - change - 27 Feb 2026
Title
Fix/route helper language parameter type 6.1
[6.1] Fix/route helper language parameter type
avatar richard67 richard67 - edited - 27 Feb 2026
avatar joomla-cms-bot joomla-cms-bot - change - 27 Feb 2026
Category Repository Administration com_admin SQL Front End com_content
avatar richard67 richard67 - change - 27 Feb 2026
Labels Added: PR-6.1-dev

Add a Comment

Login with GitHub to post a comment