maksuturva / magento2_payment_module

Svea Payment module for Magento 2
Other
4 stars 13 forks source link

Exception thrown in Model/Gateway/Implementation.php when Increment Id contains non-numeric characters #24

Open samface opened 3 years ago

samface commented 3 years ago

In Model/Gateway/Implementation.php there is line 308 that tries to mathematically add 100 to the order's increment id. This fails and results in an exception if the increment id has a non-numeric prefix or suffix. If a numeric value is really required, I suggest removing any possible prefix and suffix from the increment id first. Checkout magento/module-sales-sequence on how to fetch these values.