?
avatar BrainforgeUK
BrainforgeUK
1 Aug 2021

Steps to reproduce the issue

Install library:
lib_bftest1.zip

Expected result

Library installed, does not appear in Extensions:Discover listing

Actual result

Appears in Extensions:Discover listing and can be installed again from there.
End up with 2 records for the same library in the extensions table!

System information (as much as possible)

Windows 10
PHP 7.4

Additional comments

Found problem while using solution to issue #34910
May only be an issue in MS Windows environments, not Linux.

In com_installer/src/Model/DiscoverModel.php function discover() one key has a forward slash (/), the other a backward slash () hence the array_key_exists() function returns false instead of true.

Have solution for which I will submit a pull request shortly.

avatar BrainforgeUK BrainforgeUK - open - 1 Aug 2021
avatar joomla-cms-bot joomla-cms-bot - change - 1 Aug 2021
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 1 Aug 2021
avatar brianteeman
brianteeman - comment - 1 Aug 2021

Are you sure its nothing to with the library name?

avatar BrainforgeUK
BrainforgeUK - comment - 1 Aug 2021

The library name is:
<libraryname>brainforgeuk/test1</libraryname>

i.e. mycompany/mylibrary as in issue #34910 referred to.

Using \ instead of / does not make sense and would cause more confusion - and could such packages be installed on Linux hosts?

avatar richard67
richard67 - comment - 1 Aug 2021

The library name should neither contain a slash nor a backslash, I think. You should not try to use the library name to make up a subfolder structure.

avatar richard67
richard67 - comment - 1 Aug 2021

And if you have a PR to solve your issue (regardless if it’s right or wrong) then please close your issue.

avatar richard67 richard67 - change - 1 Aug 2021
Status New Closed
Closed_Date 0000-00-00 00:00:00 2021-08-01 21:35:06
Closed_By richard67
avatar richard67 richard67 - close - 1 Aug 2021
avatar richard67
richard67 - comment - 1 Aug 2021

Closing as having a pull request.

Add a Comment

Login with GitHub to post a comment