-
-
Save tstrohmeier/c29f60f6081860a20654248c4c2a97fa to your computer and use it in GitHub Desktop.
Magento Fatal Error when saving Order from Script with installed WirecardCEE Checkout Page installed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When a class of Wirecard_Checkoutpage_Model_* is called you get following Exception: | |
`Fatal error: Class 'WirecardCEE_QPay_PaymentType' not found in /path/app/code/core/Mage/Core/Model/Config.php on line 1354` | |
This is the case if you try to update a order. In the save method Magento tries to save Wirecard_Checkoutpage_Model_* before the order and the script crashes with an fatal error. | |
The fatal error is caused by the reason that `class_exists($className)` returns true, but `$obj = new $className($constructArguments);` is not able to find that class. | |
In front end this is no problem because in the event 'controller_front_init_before' the Observer Wirecard_CheckoutPage_Model_Autoloader->addAutoloader() is called which is adding the autoloader. | |
The _solution_ we found is: | |
`$autoloader = Mage::getModel('Wirecard_CheckoutPage_Model_Autoloader'); | |
spl_autoload_register(array($autoloader, 'autoload'), true, true);` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment