? Pending

User tests: Successful: Unsuccessful:

avatar PhilETaylor
PhilETaylor
21 May 2021

code review.

This is not used by Joomla at all, it might be used by 3PD BUT it would never work and would generate a PHP Fatal error as the method doesnt exist in the class.

Somewhere previously someone decided to deprecate the print_popup method for removal in Joomla 5.

This method calls \Joomla\Component\Content\Administrator\Service\HTML\Icon::print_popup which doesnt exist.

Rather than write that method from scratch, for an obviously deprecated future, I have taken the decision to throw an Exception, instead of a PHP Fatal error which seems to make more sense.

Without this change, if a 3PD were to implement JHtmlIcon::print_popup static method, they would get a PHP Fatal error but now they will get accurate feedback

avatar PhilETaylor PhilETaylor - open - 21 May 2021
avatar PhilETaylor PhilETaylor - change - 21 May 2021
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 21 May 2021
Category Front End com_content
avatar richard67
richard67 - comment - 21 May 2021

@PhilETaylor You wrote in the description:

Without this change, if a 3PD were to implement JHtmlIcon::print_popup static method, they will get accurate feedback and not a PHP Fatal error.

Is it a typo and you meant "With this change, ..."?

avatar PhilETaylor
PhilETaylor - comment - 21 May 2021

I obviously got distracted half way through the sentence. thanks.

Changed to

Without this change, if a 3PD were to implement JHtmlIcon::print_popup static method, they would get a PHP Fatal error but now they will get accurate feedback

avatar PhilETaylor PhilETaylor - change - 21 May 2021
The description was changed
avatar PhilETaylor PhilETaylor - edited - 21 May 2021
avatar richard67 richard67 - test_item - 21 May 2021 - Tested successfully
avatar richard67
richard67 - comment - 21 May 2021

I have tested this item successfully on 6365e9f

Code review:

avatar wilsonge wilsonge - change - 21 May 2021
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2021-05-21 16:28:11
Closed_By wilsonge
Labels Added: ?
avatar wilsonge wilsonge - close - 21 May 2021
avatar wilsonge wilsonge - merge - 21 May 2021
avatar wilsonge
wilsonge - comment - 21 May 2021

Thanks!

Add a Comment

Login with GitHub to post a comment