Update MySQLi to use the PHP API for transactions, where possible