I'm trying to modify the payment block on the order detail page in backend. Therefore I've created an observer which is listening to following event:
Now, when I'm trying to get the payment code with
$payment = $observer->getEvent()->getPayment(); $paymentmethod = $payment->getMethodInstance()->getCode();
I do get following error for credit card payments (Authorize.net) only:
PHP Fatal error: Call to a member function getCode()
Orders placed by using PayPal Express Checkout work though. Do I miss something? I appreciate any help.
Magento ver. 126.96.36.199