RTC bug PR-5.4-dev Pending

User tests: Successful: Unsuccessful:

avatar krishnagandhicode
krishnagandhicode
7 Aug 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.

What Happened/happens ?

Editing a category quietly drops any unpublished translation from its association group, and if that leaves only one member the group is deleted. Nothing warns you and republishing does not bring it back. Those translations are also missing from the Association column, which is why it is easy to miss.

Summary of Changes

Both come from CategoriesHelper::getAssociations(), which keeps only members that are published and in your view levels. Three places read associations through it: the frontend language switcher, the edit form (CategoryModel::getItem()) and the Association column (AdministratorService::association()). This Pull Request changes the last two and leaves the switcher alone.

The loss happens on save. The form renders a field per content language, a member that was filtered out submits an empty value, and AdminModel::save() then deletes the group and re-inserts only what came back.

com_categories is the only component that filters here. com_content, com_contact, com_newsfeeds and com_menus all call Associations::getAssociations() directly, which is why the same thing works for articles. com_associations reads category associations unfiltered too, so it shows the translation that the edit form hides and then deletes.

The filter came from #19551 (in 2018). Its testing instructions only mention the language switcher and the hreflang tag, and CategoryModel::getItem() was already calling the helper, so the edit form picked up a display filter it was never meant to have.

Nothing about display changes. The helper is untouched, so the language switcher still filters and #19551 still works. The form gets every member as the same integer ids it got before, and the column shows a badge for each one, like Articles already does.

Testing Instructions

On a multilingual site with at least two content languages.

  1. Content -> Categories -> New. Title Assoc demo EN, Language English (en-GB), Status Published. Save & Close.
  2. New again. Title Assoc demo FR, Language French (fr-FR), Status Unpublished. Save & Close.
  3. Open Assoc demo EN -> Associations tab -> select Assoc demo FR for French -> Save & Close.
Screenshot 2026-08-07 123206
  1. In the category list, look at the Association column on the Assoc demo EN row. (My before and after results are below)
  2. Reopen Assoc demo EN and look at the Associations tab. (My before and after results are below)
  3. Now make a edit in "Assoc demo EN" (Change the title or add some text in desc.) and Save & Close.
  4. Reopen it and look at the Associations tab again. (also verify in DB)

Actual result BEFORE applying this Pull Request

At Step 3: You can verify in DB that association is written:
Screenshot 2026-08-07 123508

At Step 4: the Assoc demo EN row shows no badge, while Assoc demo FR shows its en-GB one.
Column SS

At Step 5: the Associations tab is already empty, even though the query still returns both rows.
Screenshot 2026-08-07 124159

At Step 6 then deletes the group, so at step 7 the tab is still empty and the query returns nothing.
Screenshot 2026-08-07 124322

At any point you can check the association group in DB directly using :

SELECT a.key, a.id, c.title, c.language, c.published
FROM `#__associations` a
JOIN `#__categories` c ON c.id = a.id
WHERE a.context = 'com_categories.item' AND c.title LIKE 'Assoc demo%'
ORDER BY a.key, c.language;

With more languages the loss is partial instead of total: associate three translations, unpublish one, save the source, and the group comes back without it, leaving it an orphan.

Expected result AFTER applying this Pull Request

After applying the patch, redo step 3 to re-link the two categories, since the steps above deleted the association. Then repeat steps 4 to 7.

At Step 4: the Assoc demo EN row shows the fr-FR badge, the same as Articles shows for an unpublished associated article.
Fixed col

At Step 5: the tab shows Assoc demo FR in the French field.
Screenshot 2026-08-07 124820

Step 7: the association is still there and the query still returns both rows. With more languages every member is kept.

The language switcher is unaffected either way: an unpublished category is still left out of it and gets no hreflang.

Link to documentations

Please select:

  • Documentation link for guide.joomla.org:

  • No documentation changes for guide.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

avatar krishnagandhicode krishnagandhicode - open - 7 Aug 2026
avatar krishnagandhicode krishnagandhicode - change - 7 Aug 2026
Status New ⇒ Pending
avatar joomla-cms-bot joomla-cms-bot - change - 7 Aug 2026
Category ⇒ Administration com_categories
avatar krishnagandhicode krishnagandhicode - change - 7 Aug 2026
The description was changed
avatar krishnagandhicode krishnagandhicode - edited - 7 Aug 2026
avatar brianteeman brianteeman - test_item - 21 Aug 2026 - Tested successfully
avatar brianteeman
brianteeman - comment - 21 Aug 2026

I have tested this item ✅ successfully on 794d998


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

avatar brianteeman
brianteeman - comment - 21 Aug 2026

I have tested this item ✅ successfully on 794d998


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

avatar rvbgnu rvbgnu - test_item - 21 Aug 2026 - Tested successfully
avatar rvbgnu
rvbgnu - comment - 21 Aug 2026

I have tested this item ✅ successfully on 794d998

Great patch, thank you @krishnagandhicode


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

avatar rvbgnu
rvbgnu - comment - 21 Aug 2026

I have tested this item ✅ successfully on 794d998

Great patch, thank you @krishnagandhicode


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

avatar richard67 richard67 - change - 21 Aug 2026
Status Pending ⇒ Ready to Commit
Labels Added: PBF bug PR-5.4-dev
avatar richard67
richard67 - comment - 21 Aug 2026

RTC


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

avatar richard67
richard67 - comment - 21 Aug 2026

RTC


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

avatar rbuelund rbuelund - test_item - 22 Aug 2026 - Tested successfully
avatar rbuelund
rbuelund - comment - 22 Aug 2026

I have tested this item ✅ successfully on 794d998


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

avatar rbuelund
rbuelund - comment - 22 Aug 2026

I have tested this item ✅ successfully on 794d998


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

avatar muhme muhme - change - 26 Aug 2026
Labels Added: RTC
Removed: PBF
avatar muhme
muhme - comment - 26 Aug 2026

✅ Final test before merge with JBT, 5.4.9-dev, MariaDB, PHP 8.5

  • Installed de-DE language and Multilingual Sample Data
  • Seen lost unpublished translation if category is edited before PR
  • Applied PR with Patch Tester
    • Unpublished translation is still present after editing category
    • The two associations are shown in DB query
  • Setup new site as import from old 5.0.0 live site export, which is using 5 languages
    • Each of the 5 categories has 4 associations, 5 associations are shown with the DB query
    • Setting one category to unpublished and edited description of another category, seen one association deleted in backend and DB query before PR
    • Imported site export again and applied PR by updating the site from Joomla_5.4.9-dev+pr.48208-Development-Update_Package.zip file
      • Setting one category to unpublished and edited description of another category, doesn't change the associations in backend and DB query
      • Unpublished category is not usable on site
      • Setting the category published again and the site is full working
  • No unusual Joomla or PHP log entries were found on both instances
avatar muhme muhme - change - 26 Aug 2026
Status Ready to Commit ⇒ Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 ⇒ 2026-08-26 15:41:12
Closed_By ⇒ muhme
avatar muhme muhme - close - 26 Aug 2026
avatar muhme muhme - merge - 26 Aug 2026
avatar muhme
muhme - comment - 26 Aug 2026

Thank you very much @krishnagandhicode for your contribution. Thanks @brianteeman, @rvbgnu and @rbuelund for testing.

avatar brianteeman
brianteeman - comment - 28 Aug 2026

@krishnagandhicode just came across this #39982 is it the same thing as fixed here?

Add a Comment

Login with GitHub to post a comment