Fatal error: Call to a member function getCategory() on null
500 Internal Server Error - FatalThrowableError
Stack Trace
-
in src/PointWeb/ProductBundle/Controller/DefaultController.php at line 41
{
$em = $this->getDoctrine()->getManager();
$detail = $em->getRepository('PointWebProductBundle:Product')->find($id);
return $this->render('PointWebProductBundle:Default:show.html.twig', array('detail' => $detail, 'category' => $detail->getCategory()->getId()));
}
public function productMenuAction()
- at DefaultController ->showAction ('51')
-
at
call_user_func_array
(array(object(DefaultController), 'showAction'), array('51'))
in app/bootstrap.php.cache at line 3054 -
at
HttpKernel
->handleRaw
(object(Request), '1')
in app/bootstrap.php.cache at line 3016 -
at
HttpKernel
->handle
(object(Request), '1', true)
in app/bootstrap.php.cache at line 3165 -
at
ContainerAwareHttpKernel
->handle
(object(Request), '1', true)
in app/bootstrap.php.cache at line 2406 -
at
Kernel
->handle
(object(Request))
in web/app.php at line 28