Ldap\Connection: Return false if nothing is found for fetchOne()

This should behave like DbConnection::fetchOne().

refs #8954
This commit is contained in:
Johannes Meyer 2015-06-23 12:41:50 +02:00
parent 6d8c56a12f
commit 9d6d76a26d

View File

@ -143,7 +143,7 @@ class Connection implements Selectable
public function fetchOne($query, $fields = array())
{
$row = (array) $this->fetchRow($query, $fields);
return array_shift($row);
return array_shift($row) ?: false;
}
public function hasDN($dn)