Further testing reveals that the actual page in question where I am encountering this error (mysite/wp-admin/users.php) gets as far as line 335:
$wp_list_table->prepare_items();
When the myCred plugin is active, the users page parses up to that line then everything grinds to a halt with the aforementioned undefined method error.
Plugin Author
myCred
(@designbymerovingi)
Hi
Thank you for reporting this. Looking at the WP_User_Query documentation it seems the get method was introduced first in WP 3.5.
I will look into adding some fix for older WP versions.
Plugin Author
myCred
(@designbymerovingi)
Delete your current myCRED installation and re-download + install to resolve this issue.
Alternativly if you do not want to loose existing log entries you can open the mycred-admin.php file in plugins/mycred/includes/ and on line 143 replace the existing sort_by_points() function with the following:
/**
* Sort by Points
* @since 1.2
* @version 1.2
*/
public function sort_by_points( $query ) {
if ( !is_admin() ) return;
$screen = get_current_screen();
if ( $screen->id != 'users' ) return;
if ( isset( $query->query_vars['orderby'] ) && isset( $query->query_vars['order'] ) && $query->query_vars['orderby'] == 'mycred' ) {
global $wpdb;
$cred_id = $this->core->get_cred_id();
$order = $query->query_vars['order'];
$query->query_from .= " LEFT JOIN {$wpdb->usermeta} ON ({$wpdb->users}.ID = {$wpdb->usermeta}.user_id AND {$wpdb->usermeta}.meta_key = '$cred_id')";
$query->query_orderby = "ORDER BY {$wpdb->usermeta}.meta_value+0 $order ";
}
}
Excellent!
The above changes worked like a charm! Thank you for your prompt and efficient support!