->getRepository('WallabagAnnotationBundle:Annotation')
->findAnnotationsByPageId($entry->getId(), $this->getUser()->getId());
$total = count($annotationRows);
- $annotations = array('total' => $total, 'rows' => $annotationRows);
+ $annotations = ['total' => $total, 'rows' => $annotationRows];
$json = $this->get('serializer')->serialize($annotations, 'json');
*/
private function renderJsonResponse($json, $code = 200)
{
- return new Response($json, $code, array('application/json'));
+ return new Response($json, $code, ['application/json']);
}
}