View Issue Details

IDProjectCategoryView StatusLast Update
0007754module Easy CreditGeneralpublic2024-12-17 06:42
Reportermount7 Assigned To 
PrioritynormalSeverityminorReproducibilityhave not tried
Status assignedResolutionopen 
Product Version3.0.8 
Summary0007754: ModuleChainGenerator has issue loading EasyCreditPayment
DescriptionPHP Warning: Class 'OxidProfessionalServices\EasyCredit\Core\Domain\EasyCreditPayment' not found in /...

Class exists at the specific location and everything works fine if you put EasyCreditPayment at the end of the list for the Payment Model extensions.

Removing the static function inside the EasyCreditPayment.php seems to resolve the module chain issue.
Deactivating the module solves the issue to.

=> Is there an issue with using static functions inside class extensions?
Steps To Reproduce1. Shop with multiple modules extending the Payment Model
2. Put EasyCreditPayment above a required extension in the module extension chain
3. Crash the shop
Additional Information- es -
TagsNo tags attached.

Activities

QA

2024-12-09 14:42

administrator   ~0017762

I tried to reproduce the behavior in an EE 6.5.4 with EasyCredit v3.0.8 and Unzer Payment v1.2.1.
I entered EasyCreditPayment before Unzer Payment in the list (see attachment) and did not get a warning in oxideshop.log.

PHP Warning: Class 'OxidProfessionalServices\EasyCredit\Core\Domain\EasyCreditPayment' not found in /...

QA

2024-12-09 14:42

administrator   ~0017763

Easycredit01.jpg (101,165 bytes)   
Easycredit01.jpg (101,165 bytes)   
Easycredit02.jpg (81,455 bytes)   
Easycredit02.jpg (81,455 bytes)   

mount7

2024-12-09 14:52

reporter   ~0017764

I entered EasyCreditPayment before Unzer Payment in the list (see attachment) and did not get a warning in oxideshop.log.
=> Please check php error log and not the oxid log

QA

2024-12-10 13:27

administrator   ~0017766

PHP Error.log:
PHP Warning: Class "OxidProfessionalServices\\EasyCredit\\Core\\Domain\\EasyCreditPayment" not found in /var/www/oxideshop/vendor/oxid-esales/oxideshop-ce/source/Core/Module/ModuleChainsGenerator.php on line 306, referer: https://t2.oxid.academy/index.php?
modulclassgenerator.jpg (152,479 bytes)   
modulclassgenerator.jpg (152,479 bytes)   

Joatiya

2024-12-17 06:42

reporter   ~0017773

Hello,
It seems that the issue is related to the order in which the modules are loaded. The EasyCreditPayment class might be conflicting with other modules when placed higher in the chain;;, especially with the use of static functions. Static methods can sometimes cause issues in the order of execution or initialization, particularly when dependencies are involved. As you have noted..., deactivating the module or removing the static function resolves the issue. Consider refactoring the code to avoid using static methods in class extensions to ensure smoother module interaction.

Thanks
https://www.igmguru.com/cyber-security/ccsp-isc2-certification-training