- fixed cache users count;

This commit is contained in:
nikitozzzzzzz
2018-05-01 00:29:45 +03:00
parent cbb9287534
commit 1d3351ec5e
+6 -7
View File
@@ -1,11 +1,10 @@
<?php $all_options = wp_load_alloptions();
<?php global $wpdb;
$count = 0;
foreach ( $all_options as $k => $v ) {
if ( strstr( $k, 'um_cache_userdata_' ) !== false ) {
$count++;
}
} ?>
$count = $wpdb->get_var(
"SELECT COUNT( option_id )
FROM {$wpdb->options}
WHERE option_name LIKE 'um_cache_userdata_%'"
); ?>
<p><?php _e( 'Run this task from time to time to keep your DB clean.', 'ultimate-member' ) ?></p>
<p>