Is their any way we can continue execution of program after below exception
throw new \Magento\Framework\Exception\LocalizedException(
__('If the invoice was created offline, try creating an offline credit memo.'),
$e
);
Actually i have created an shipment refund script that refunds shipment for orders. i pass order id in csv & it created online credit memo. But for some order (that i don't know). get stuck in below exception, That is why the next order id does not gets executed. Is their any way i can skip this exception or check something in script to prevent call going into this code ?
Magento2/vendor/magento/module-sales/Model/Order/Payment.php
throw new \Magento\Framework\Exception\LocalizedException(
__('If the invoice was created offline, try creating an offline credit memo.'),
$e
);