diff --git a/system/libs/pot/OTS_Account.php b/system/libs/pot/OTS_Account.php index 45958b06..2e493126 100644 --- a/system/libs/pot/OTS_Account.php +++ b/system/libs/pot/OTS_Account.php @@ -343,7 +343,17 @@ class OTS_Account extends OTS_Row_DAO implements IteratorAggregate, Countable return round(($this->data['lastday'] - time()) / (24 * 60 * 60), 3); //return $this->data['premdays'] - (date("z", time()) + (365 * (date("Y", time()) - date("Y", $this->data['lastday']))) - date("z", $this->data['lastday'])); } + + public function getLastLogin() + { + if( !isset($this->data['lastday']) ) + { + throw new E_OTS_NotLoaded(); + } + return $this->data['lastday']; + } + public function isPremium() { global $config;