Make WordPress Core


Ignore:
Timestamp:
11/08/2023 08:31:34 PM (15 months ago)
Author:
hellofromTonya
Message:

Database: Reinstate wpdb::$use_mysqli property.

Partial revert of [56475] to reinstate the private wpdb::$use_mysqli property and set to its default to true. This private property was / is accessible through the magic methods. Though Core's usage of this property was removed by [56475], plugins are using the property. Reinstating it resolves the BC break.

Follow up to [56475].

Props jason_the_adams, joemcgill, johnbillion, johnjamesjacoby, jrf, rajinsharwar, renehermi.
Fixes #59846.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/db.php

    r56475 r57089  
    24702470        );
    24712471    }
     2472
     2473    /**
     2474     * This private property is no longer used but needs to be retained as it can be
     2475     * accessed externally due to the `__get()` magic method.
     2476     *
     2477     * @ticket 59118
     2478     * @ticket 59846
     2479     */
     2480    public function test_use_mysqli_property_access() {
     2481        global $wpdb;
     2482
     2483        $this->assertTrue( $wpdb->use_mysqli );
     2484    }
    24722485}
Note: See TracChangeset for help on using the changeset viewer.