Magento Certified Developer GuideCategory: 8. CheckoutHow can the stored data of payment methods be customized (credit card numbers, for example)?
Manish Prakash Staff asked 2 years ago

Before data is stored in database the method prepareSave() is called on the payment method.
We can write a custom prepareSave() method and write our

public function prepareSave()
        $info = $this->getInfoInstance();
        if ($this->_canSaveCc) {
        return $this;