/wp-db.php Secret
Created
October 31, 2016 21:53
Add this code to the WordPress wpdb::get_results method.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Add the following testing code into the `wp-includes/wp-db.php` file | |
* This snippet of code will trigger our plugin's recorder. | |
*/ | |
public function get_results( $query = null, $output = OBJECT ) { | |
// TESTING - TONYA | |
if ( function_exists( 'UpTechLabs\KnowTheCode\GroupbyLab\record_database_hit' ) ) { | |
\UpTechLabs\KnowTheCode\GroupbyLab\record_database_hit( $query ); | |
} | |
// TESTING-END - TONYA |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment