mirror of
https://github.com/InvoiceShelf/InvoiceShelf.git
synced 2026-09-08 16:14:13 +00:00
PHP 8.5 deprecated PDO::MYSQL_ATTR_SSL_CA in favour of Pdo\Mysql::ATTR_SSL_CA, so on 8.5 every test in the suite was reported as deprecated rather than passed — noise that would hide a real one. Pdo\Mysql does not exist before 8.5 and this package supports ^8.4, so the constant is resolved at runtime; the untaken ternary branch is never looked up, which keeps 8.4 working. The lookup stays behind the extension_loaded() check because neither name is defined when pdo_mysql is missing. Verified against both runtimes: with MYSQL_ATTR_SSL_CA set, 8.4 resolves to attribute 1009 and 8.5 to 1008 — each version's own value, matching what the previous code produced there. Same change as InvoiceShelf/InvoiceShelf#696 on 3.x.