No Code Attached Yet
avatar durian808
durian808
13 Mar 2022

The code change you proposed is wrong.
The other bugs you linked to are not related.
The problem is that the code in the plugin is wrong. It will never have worked if for example the site was installed in a subdirectory.

Joomla should not change its code to account for bad code by a third party

My comment referred to the code in the plugin that should be changed not the code in Joomla

Originally posted by @brianteeman in #37257 (comment)

avatar durian808 durian808 - open - 13 Mar 2022
avatar joomla-cms-bot joomla-cms-bot - change - 13 Mar 2022
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 13 Mar 2022
avatar durian808
durian808 - comment - 13 Mar 2022

Then why was the function adding JPATH_ROOT to the beginning of the path? It's because the authors of the function realized that a leading "/" might be passed. That's good, that's defensive programming. It points out the fact that is_dir() and is_file() have a new behavior with a new version of PHP, and this was not something the original authors knew about.

What we have here is the admin UI of Virtuemart spitting out a warning. Isn't it bad coding in Joomla that Joomla isn't giving an understandable error – i.e. rejecting the input with an understandable error message – instead of relying on a PHP function to spit out a cryptic warning?

I'm concerned that there are many instances of is_dir() and is_file() being used in the Joomla core, and this issue may pop up again and again, resulting in Joomla spitting out this PHP warning in lots of extensions. Wouldn't it be prudent to examine all the code and make appropriate modifications?

And what about my treatment in #37241? I was not treated very well. Do you want people to report bugs? I mean I was honestly reporting what I thought was something Joomla should not be doing, and I was treated very poorly.

thanks

avatar richard67 richard67 - change - 13 Mar 2022
Status New Closed
Closed_Date 0000-00-00 00:00:00 2022-03-13 13:22:24
Closed_By richard67
avatar richard67 richard67 - close - 13 Mar 2022
avatar richard67
richard67 - comment - 13 Mar 2022

And what about my treatment in #37241? I was not treated very well. Do you want people to report bugs? I mean I was honestly reporting what I thought was something Joomla should not be doing, and I was treated very poorly.

@durian808 As I have already explained in your previous issue, it was you who first started to treat people poorly by becoming unfriendly.

You had your chance to think about your behaviour.

Add a Comment

Login with GitHub to post a comment