/** * Return users last visit * * @param void * @return DateTimeValue */ function getLastVisitOn() { if ($this->last_visit_on === false) { $last_visit = parent::getLastVisitOn(); $this->last_visit_on = instance_of($last_visit, 'DateTimeValue') ? $last_visit : new DateTimeValue(filectime(ENVIRONMENT_PATH . '/config/config.php')); } // if return $this->last_visit_on; }