summaryrefslogtreecommitdiffstats
path: root/lib/class/user.class.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/class/user.class.php')
-rw-r--r--lib/class/user.class.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/class/user.class.php b/lib/class/user.class.php
index 27d901bf..60c605fc 100644
--- a/lib/class/user.class.php
+++ b/lib/class/user.class.php
@@ -726,8 +726,12 @@ class User extends database_object {
$this->f_useage = round($total,2) . $name;
/* Get Users Last ip */
- $data = $this->get_ip_history(1);
- $this->ip_history = inet_ntop($data['0']['ip']);
+ if (count($data = $this->get_ip_history(1))) {
+ $this->ip_history = inet_ntop($data['0']['ip']);
+ }
+ else {
+ $this->ip_history = _('Not Enough Data');
+ }
} // format_user