public function __construct($username, $password, $error = '')
 {
     $this->username = $username;
     $this->password = $password;
     $this->error = $error;
     $this->Dbfactory = DbFactory::getinstance();
     $this->handleLogin($username, $password);
 }