Open Source
Shaping the tools I use every day, one pull request at a time
A hand-picked selection: only the contributions worth reading about, not every merged pull request. Articles about Magento and Adobe Commerce are on the blog.
Pass pay method type and value to updatePayment in the declared order — on GitHub
RepayOrder::execute() passed the pay method and its type to updatePayment() in reverse order. After every repay, payu_method and payu_method_type in the order payment’s additional information held each other’s value, so a BLIK repay was stored as method PBL with type blik.
Define the request body before the try block in PayUAbstractClient — on GitHub
When setDefaultConfig() threw, the catch block in placeRequest() read a $body that was never assigned. Magento turned the warning into an exception, the shopper got a generic server error, nothing reached payugateway.log, and the real cause (for example Empty PayU Configuration) was lost. The body is now read before the try, so configuration errors are logged with their message again.
Show the quote grand total on the Google Pay and Apple Pay sheets — on GitHub
The Google Pay and Apple Pay sheets took the amount from base_grand_total but the currency from quote_currency_code. On a store with base currency PLN and checkout currency EUR, the sheet showed the PLN amount labelled as EUR, which was not the amount sent to PayU. Both sheets now read grand_total, matching the order request; single-currency stores see no change.
Use HTTPS for the PayU terms link — on GitHub
The terms of service link on the payment step and the repay page pointed to an http:// URL from an HTTPS checkout. The constant now uses https://, which static.payu.com already serves.
Set a timeout on the Shield rules fetch — on GitHub
Magento\Framework\HTTP\Client\Curl sets no default timeout, so a stalled connection to the rules endpoint blocked fetchRules() indefinitely. That call runs from a cron job in a separate process, and Magento’s schedule lifetime only prunes stale rows after the fact — it never kills the hung worker.
Cache the WAF rules in front of the flag lookup — on GitHub
The plugin injects the WAF eagerly, so every request paid for a point SELECT on the flag table before it could decode the rules — a round trip for a value that only changes when the five-minute cron writes it. Caching in front of that lookup, without reintroducing the cache-only storage the module had deliberately dropped, since cache:flush or a disabled cache type must not leave the WAF ruleless.
Escape table names so encryption key rotation survives them — on GitHub
Table names containing special characters broke the generated SQL mid-rotation — a bad moment to discover a quoting bug, given what the tool is re-encrypting.
Prefetch orders to kill an N+1 in the admin grid — on GitHub
The orders grid issued one query per row for Mailchimp data. Prefetching cut over 20% of the grid load locally — more on any environment with real network latency to the database.
Run ExtensionChecker without a working Magento install — on GitHub
The dependency scanner required a fully bootstrapped Magento, which is precisely what you do not have when auditing a pile of modules in CI.
Only merged work is listed here, and only the parts worth a comment — the full history, including everything still in review, lives on GitHub .
RepayOrderResolverAbstract::execute()used$this->customerSessionand$this->urlBuilder, but the class only injected the command pool. A repay that PayU answered withSUCCESSand no redirect, or withWARNING_CONTINUE_CVV, ended in “Can’t repay order.” after the PayU order was already created. Both dependencies are now injected in the abstract constructor and autowired for the four concrete resolvers, with nodi.xmlchange.