No Code Attached Yet bug
avatar stefanoel
stefanoel
17 Jun 2025

Steps to reproduce the issue

  1. From backend, create two category: CAT1 and CAT2.
  2. Create an article, assign it to CAT1 and save it.
  3. Then, reassign the article to CAT2 and save again.
  4. Now, delete permanently CAT1.
  5. Edit the article, restoring the previous version (the one assigned to CAT1).
  6. The article content is restored. The Category field shows "CAT2" so I assume everything is ok.
  7. Don't save, click on Close (saving won't cause the issue).

Expected result

The content is restored and the article should be assigned to CAT2, the category showed in the Category field after the restore.

Actual result

The content is correctly restored, but looking at the list of articles I can see that the article has un undefined category, like this:

Article title
Alias: article
Category: » » (Trashed)

In the #__content table, the catid field has the id of CAT1, the removed category.
Viewing the article from frontend I get a 404 error, I guess because the article is assigned to a nonexistent category.

To resolve, I have to edit the article from the backend: the category field in the form shows automatically CAT2 (the first category available). Saving the article solves the problem, reassigning it to an existing category.

System information (as much as possible)

PHP 8, Joomla 5.3.1

Additional comments

From the frontend, reproducing the above steps, cause an additional problem because after restoring, the 404 error prevents me to access the edit form.

avatar stefanoel stefanoel - open - 17 Jun 2025
avatar joomla-cms-bot joomla-cms-bot - change - 17 Jun 2025
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 17 Jun 2025
avatar chmst chmst - change - 21 Jun 2025
Labels Added: bug
avatar chmst chmst - labeled - 21 Jun 2025

Add a Comment

Login with GitHub to post a comment