No Code Attached Yet bug
avatar dawe78
dawe78
29 Apr 2022

Steps to reproduce the issue

Backend: go to content -> media, create new directory >test.png< (which makes no sense, but a customer of me did and caused the error)

Expected result

  • show message "can't create directory"
  • directory was not created
  • com_media keeps working

Actual result

  • message is shown
  • directory was created
  • com_media shows no content any more; on some systems message "image not found" appears, but not for all systems (dont know why the behaviour is different for same release number systems)

System information (as much as possible)

Joomla 4.1.2 (current stable)
PHP 7.4

Additional comments

maybe a solution could be to check if current string is a directory or file; currently com_media treats directorys as file if name syntax matches to file name syntax and tries to get fileinfo for directory, thats why com_media crashes. before getting fileinfo, com_media should check if current string is file or not.

avatar dawe78 dawe78 - open - 29 Apr 2022
avatar joomla-cms-bot joomla-cms-bot - change - 29 Apr 2022
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 29 Apr 2022
avatar chmst
chmst - comment - 1 May 2022

Confirmed online PHP 8.0
grafik

On my localhost win11, php 8.1 I see that directories are gernerated for example xx.png, test.jpg.

avatar chmst chmst - change - 1 May 2022
Labels Added: bug
avatar chmst chmst - labeled - 1 May 2022
avatar ReLater
ReLater - comment - 1 May 2022

Expected result
show message "can't create directory"
directory was not created

I think it should be created. Why not?

Of course, as long as

com_media keeps working

avatar chmst
chmst - comment - 1 May 2022

Directories are created for example xx.png, test.jpg.
These directories are only visible in my local installation (I am on win11), not online (via ftp).

As long as these directories exist, no directory tree is displayed - see screenshot

avatar dawe78
dawe78 - comment - 2 May 2022

ReLater I agree; what I meant was the directory has been created although the message said it was not - what possibly is a bug. But youre right, there is no reason NOT to create a directory like this, so this message has to be removed.

avatar Quy Quy - change - 24 Feb 2024
Status New Closed
Closed_Date 0000-00-00 00:00:00 2024-02-24 18:37:11
Closed_By Quy
avatar Quy Quy - close - 24 Feb 2024
avatar Quy
Quy - comment - 24 Feb 2024

Closing per #42874.

Add a Comment

Login with GitHub to post a comment