diff --git a/lam/lib/modules/nisNetGroupUser.inc b/lam/lib/modules/nisNetGroupUser.inc index c491e3146..8cacc7645 100644 --- a/lam/lib/modules/nisNetGroupUser.inc +++ b/lam/lib/modules/nisNetGroupUser.inc @@ -355,10 +355,10 @@ class nisNetGroupUser extends baseModule { continue; } $triples = empty($current['nisnetgrouptriple']) ? array() : $current['nisnetgrouptriple']; - if (!empty($changeSet['del'])) { + if (isset($changeSet['del'])) { $triples = array_delete($changeSet['del'], $triples); } - if (!empty($changeSet['add'])) { + if (isset($changeSet['add'])) { $triples = array_merge($changeSet['add'], $triples); } $triples = array_values(array_unique($triples)); diff --git a/lam/lib/webauthn.inc b/lam/lib/webauthn.inc index b42aede9e..07f918a9e 100644 --- a/lam/lib/webauthn.inc +++ b/lam/lib/webauthn.inc @@ -709,7 +709,7 @@ abstract class PublicKeyCredentialSourceRepositoryBase implements PublicKeyCrede $pdo = $this->getPDO(); $statement = $pdo->prepare('delete from ' . $this->getTableName()); $statement->execute(); - if (empty($data)) { + if ($data === null) { return; } foreach ($data as $dbRow) {