Feature b/c break PR-7.0-dev Pending

User tests: Successful: Unsuccessful:

avatar Hackwar
Hackwar
20 Mar 2026
  • 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

As with everywhere in Joomla, we shouldn't be implementing custom database object setters and getters and instead use the DatabaseAwareTrait instead. The Table class has the methods getDbo(), setDbo(), getDatabase() and setDatabase() to retrieve the db object. The first 2 are supposed to be removed and the later 2 are only there to make the transition to the trait smoother. With the removal of the former 2, we can completely rely on the trait and remove the later 2 as well.

Testing Instructions

Codereview

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: joomla/Manual#600

  • No documentation changes for manual.joomla.org needed

avatar Hackwar Hackwar - open - 20 Mar 2026
avatar Hackwar Hackwar - change - 20 Mar 2026
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 20 Mar 2026
Category Libraries
avatar Hackwar Hackwar - change - 20 Mar 2026
Labels Added: PR-7.0-dev
avatar Hackwar
Hackwar - comment - 2 Apr 2026

What exactly do you mean?

avatar Hackwar Hackwar - change - 3 Apr 2026
The description was changed
avatar Hackwar Hackwar - edited - 3 Apr 2026
avatar Hackwar Hackwar - change - 3 Apr 2026
Labels Added: Feature b/c break
avatar Hackwar
Hackwar - comment - 3 Apr 2026

Yes, replacing $table->getDbo() with Factory::getDbo() is bad, but since getDatabase() is not public and since the Tagshelper class already contains 13 other cases where it uses Factory::getDbo(), I'm willing to take the fall here and replace one deprecated method with another deprecated method. At least then we have one issue solved entirely.

Add a Comment

Login with GitHub to post a comment