--- user_stats.module 2009-02-15 00:50:09.000000000 +0300 +++ user_statsNew.module 2009-02-25 10:59:39.000000000 +0300 @@ -90,7 +90,10 @@ function user_stats_get_stats($type, $ui // IP address is really a bit of feature creep. // At some point in the future, this could be split off into its own module. - if ($type == 'ip_address' && user_access('View IP addresses')) { + if ($type == 'ip_address') { + if (!user_access('View IP addresses')) { + return FALSE; + } // Check cache. if (user_stats_cache_get($type, $uid) === FALSE) { $query = db_query("SELECT MAX(ip_address)