diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index cab6a5eeb..3e8d79b3d 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -20,11 +20,6 @@ parameters: count: 1 path: src/Bundle/ChillDocGeneratorBundle/Controller/DocGeneratorTemplateController.php - - - message: "#^Short ternary operator is not allowed\\. Use null coalesce operator if applicable or consider using long ternary\\.$#" - count: 1 - path: src/Bundle/ChillDocStoreBundle/EntityRepository/DocumentCategoryRepository.php - - message: "#^Variable \\$participation might not be defined\\.$#" count: 3 diff --git a/src/Bundle/ChillDocStoreBundle/EntityRepository/DocumentCategoryRepository.php b/src/Bundle/ChillDocStoreBundle/EntityRepository/DocumentCategoryRepository.php index d803405e4..72c068d18 100644 --- a/src/Bundle/ChillDocStoreBundle/EntityRepository/DocumentCategoryRepository.php +++ b/src/Bundle/ChillDocStoreBundle/EntityRepository/DocumentCategoryRepository.php @@ -34,6 +34,6 @@ class DocumentCategoryRepository extends EntityRepository 'SELECT MAX(c.idInsideBundle) + 1 FROM ChillDocStoreBundle:DocumentCategory c') ->getSingleResult(); - return $array_res[1] ?: 0; + return reset($array_res); } }