Making WordPress.org

Ticket #2514: meta-2514.2.patch

File meta-2514.2.patch, 1.3 KB (added by SergeyBiryukov, 8 years ago)
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-bbp-user-badges/inc/class-plugin.php

     
    353353                        if ( 'plugin' === $type ) {
    354354                                // Get users who have commit access.
    355355                                $authors = $wpdb->get_col( $wpdb->prepare(
    356                                         "SELECT user FROM plugin_2_svn_access WHERE `path` = %s",
     356                                        "SELECT user FROM " . PLUGINS_TABLE_PREFIX . "svn_access WHERE `path` = %s",
    357357                                        '/' . $slug
    358358                                ) );
    359359                        }
     
    395395                        if ( 'plugin' === $type ) {
    396396                                // TODO: Change this when the Plugin Directory switches over to WordPress.
    397397                                $contributors = $wpdb->get_var( $wpdb->prepare(
    398                                         'SELECT meta_value FROM plugin_2_meta m LEFT JOIN plugin_2_topics t ON m.object_id = t.topic_id WHERE t.topic_slug = %s AND m.object_type = %s AND m.meta_key = %s',
     398                                        'SELECT meta_value FROM ' . PLUGINS_TABLE_PREFIX . 'meta m LEFT JOIN ' . PLUGINS_TABLE_PREFIX . 'topics t ON m.object_id = t.topic_id WHERE t.topic_slug = %s AND m.object_type = %s AND m.meta_key = %s',
    399399                                        $slug,
    400400                                        'bb_topic',
    401401                                        'contributors'