mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 23:23:51 +00:00
fix: SA: Fix "...Variable in isset() is never defined...." rule.
SA stands for Static Analysis.
This commit is contained in:
@@ -347,7 +347,6 @@ class ApiController extends AbstractCRUDController
|
||||
*
|
||||
* @param string $action
|
||||
* @param Request $request
|
||||
* @return type
|
||||
*/
|
||||
protected function indexApiAction($action, Request $request, $_format)
|
||||
{
|
||||
@@ -358,9 +357,7 @@ class ApiController extends AbstractCRUDController
|
||||
return $response;
|
||||
}
|
||||
|
||||
if (!isset($entity)) {
|
||||
$entity = '';
|
||||
}
|
||||
$entity = '';
|
||||
|
||||
$response = $this->onPostCheckACL($action, $request, $_format, $entity);
|
||||
if ($response instanceof Response) {
|
||||
@@ -370,8 +367,13 @@ class ApiController extends AbstractCRUDController
|
||||
$totalItems = $this->countEntities($action, $request, $_format);
|
||||
$paginator = $this->getPaginatorFactory()->create($totalItems);
|
||||
|
||||
$response = $this->onPreIndexBuildQuery($action, $request, $_format, $totalItems,
|
||||
$paginator);
|
||||
$response = $this->onPreIndexBuildQuery(
|
||||
$action,
|
||||
$request,
|
||||
$_format,
|
||||
$totalItems,
|
||||
$paginator
|
||||
);
|
||||
|
||||
if ($response instanceof Response) {
|
||||
return $response;
|
||||
|
Reference in New Issue
Block a user