Installing component and module at the same time causes install error #941
Labels
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: joomla/Component-Builder#941
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Steps to reproduce the issue
Expected result
Install of both component and module
Actual result
Error "com_COMPONENTNAMEInstallerScript::preflight() must be an instance of Joomla\CMS\Installer\Adapter\ComponentAdapter, instance of Joomla\CMS\Installer\Adapter\ModuleAdapter given"
System information (as much as possible)
Additional comments
I blocked out the exact name of component in the image but that should not have an effect on the issue. Installing the component and module by themself works fine, it's just when you try to install both it goes wrong
I think this is still an error related to this issue, can you try the tmp fix... and let me know?
That does indeed fix the issue. I can try to debug this and make a pull request if that's gonna save you some time?
Your welcome, but I can tell you what is wrong.... and I kinda know how to fix it...
So what goes wrong is the install class for the plugin does not get build correctly so if we add a field... in the GUI then the class get build.
So for the module we have to just from a_Get.php line-9737 we need to add the following... as a test:
So for the plugin we have to just from a_Get.php line-10644 we need to add the following... as a test:
I think this will resolve the issue, but I have not had time to test this.
Should that not work, there is two more things to try... let me know.
When i set add_install_script to true it indeed installs correctly. Thanks!
I looked a bit further and in f_Infusion.php line 2390 there is this code:
The same goes for the plugin install (but that one is on line 2453). Is this something you want to add to the next update yourself or would you like me to make a pull request?
I just needed someone to test that... if it works then I can make the change, no problem.