DbUserBackend: Drop redundant method hasUser

refs #8826
This commit is contained in:
Johannes Meyer 2015-04-21 13:14:50 +02:00
parent a7af546078
commit 11f522d929
1 changed files with 0 additions and 17 deletions

View File

@ -39,23 +39,6 @@ class DbUserBackend extends UserBackend
$this->conn = $conn;
}
/**
* Test whether the given user exists
*
* @param User $user
*
* @return bool
*/
public function hasUser(User $user)
{
$select = new Zend_Db_Select($this->conn->getDbAdapter());
$row = $select->from('icingaweb_user', array(new Zend_Db_Expr(1)))
->where('name = ?', $user->getUsername())
->query()->fetchObject();
return ($row !== false) ? true : false;
}
/**
* Add a new user
*