WordPress.org

Make WordPress Core

Ticket #5699: get_col.diff

File get_col.diff, 566 bytes (added by fitztrev, 6 years ago)
  • wp-includes/comment.php

     
    992992        } 
    993993 
    994994        // Do Trackbacks 
    995         $trackbacks = $wpdb->get_results("SELECT ID FROM $wpdb->posts WHERE to_ping <> '' AND post_status = 'publish'"); 
     995        $trackbacks = $wpdb->get_col("SELECT ID FROM $wpdb->posts WHERE to_ping <> '' AND post_status = 'publish'"); 
    996996        if ( is_array($trackbacks) ) { 
    997997                foreach ( $trackbacks as $trackback ) 
    998998                        do_trackbacks($trackback->ID);