X-Git-Url: https://git.rapsys.eu/userbundle/blobdiff_plain/b50edfff7f68b16418110a8ed17d6b514dc9d1c6..ffeb0f7e44aa00f2f163e20e4ca3e03a8b790653:/Repository/UserRepository.php?ds=sidebyside diff --git a/Repository/UserRepository.php b/Repository/UserRepository.php index ec5ffa3..13dc2f0 100644 --- a/Repository/UserRepository.php +++ b/Repository/UserRepository.php @@ -26,13 +26,13 @@ class UserRepository extends Repository implements PasswordUpgraderInterface { /** * Find user count as int * - * @return integer The keywords count + * @return integer The users count */ public function findCountAsInt(): int { //Set the request $req = <<addScalarResult('mail', 'mail', 'string') ->addScalarResult('forename', 'forename', 'string') ->addScalarResult('surname', 'surname', 'string') - ->addScalarResult('g_id', 'g_id', 'integer') ->addScalarResult('g_title', 'g_title', 'string'); //Fetch result @@ -119,7 +118,7 @@ SQL; //Process result foreach($res as $data) { //Get translated group - $group = $this->translator->trans($data['g_title'], [], $this->alias); + $group = $this->translator->trans($data['g_title']?:'Null', [], $this->alias); //Init group subarray if (!isset($ret[$group])) {