Exceptions
Exception
Twig\Error\ RuntimeError
{% extends 'TroikaRealEstateBundle:Default:layout.html.twig' %}{% block title %}{{ news.metaTitle }}{% endblock %}{% block description %}{{ news.metaDescription }}{% endblock %}{% block keywords %}{{ news.metaKeywords }}{% endblock %}{% block ogTitle %}{{ news.name }}{% endblock %}{% block ogImg %}{% for photo in news.photos %}
in
var/cache/dev/twig/db/dbd45425926edd0038fad456826b7fe85b68267251d524a7e3b96accb04d3db9.php
twig_get_attribute
(line 72)
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "title"));$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "title"));echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["news"]) || array_key_exists("news", $context) ? $context["news"] : (function () { throw new RuntimeError('Variable "news" does not exist.', 4, $this->source); })()), "metaTitle", [], "any", false, false, false, 4), "html", null, true);$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
in
vendor/twig/twig/src/Template.php
->
block_title
(line 182)
in
var/cache/dev/twig/03/03bf7d28cfa1cd368d82e952ede644e39f786b3510e64009384a644776c3aedb.php
->
displayBlock
(line 65)
<meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\"><meta name=\"viewport\" content=\"width=device-width; initial-scale=1.0; maximum-scale=1.0, shrink-to-fit=no; \"/><meta name=\"cmsmagazine\" content=\"d861abde084bbfe4c6a397bda4831501\"/><title>";// line 9$this->displayBlock('title', $context, $blocks);echo "</title><meta name=\"description\" content=\"";// line 10$this->displayBlock('description', $context, $blocks);echo "\">
in
vendor/twig/twig/src/Template.php
->
doDisplay
(line 405)
in
vendor/twig/twig/src/Template.php
->
displayWithErrorHandling
(line 378)
in
var/cache/dev/twig/db/dbd45425926edd0038fad456826b7fe85b68267251d524a7e3b96accb04d3db9.php
->
display
(line 53)
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "TroikaRealEstateBundle:About:news_item.html.twig"));$this->parent = $this->loadTemplate("TroikaRealEstateBundle:Default:layout.html.twig", "TroikaRealEstateBundle:About:news_item.html.twig", 1);$this->parent->display($context, array_merge($this->blocks, $blocks));$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
in
vendor/twig/twig/src/Template.php
->
doDisplay
(line 405)
in
vendor/twig/twig/src/Template.php
->
displayWithErrorHandling
(line 378)
in
vendor/twig/twig/src/Template.php
->
display
(line 390)
in
vendor/symfony/twig-bridge/TwigEngine.php
->
render
(line 54)
in
vendor/symfony/framework-bundle/Controller/ControllerTrait.php
->
render
(line 233)
protected function render(string $view, array $parameters = [], Response $response = null): Response{if ($this->container->has('templating') && $this->container->get('templating')->supports($view)) {@trigger_error('Using the "templating" service is deprecated since version 4.3 and will be removed in 5.0; use Twig instead.', \E_USER_DEPRECATED);$content = $this->container->get('templating')->render($view, $parameters);} elseif ($this->container->has('twig')) {$content = $this->container->get('twig')->render($view, $parameters);} else {throw new \LogicException('You can not use the "render" method if the Templating Component or the Twig Bundle are not available. Try running "composer require symfony/twig-bundle".');}
AbstractController->render()
in
src/Troika/RealEstateBundle/Controller/DefaultController.php
(line 431)
public function newsItemAction($id){$news = $this->container->get('news.model')->getOne($id);$links = $this->container->get('news.model')->getPage(1);return $this->render('TroikaRealEstateBundle:About:news_item.html.twig', ['news' => $news, 'links' => $links]);}public function newsItemSlugAction($slug, $id){$news = $this->container->get('news.model')->getSlug($slug, $id);
in
vendor/symfony/http-kernel/HttpKernel.php
->
newsItemAction
(line 169)
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);$controller = $event->getController();$arguments = $event->getArguments();// call controller$response = $controller(...$arguments);// viewif (!$response instanceof Response) {$event = new ViewEvent($this, $request, $type, $response);$this->dispatcher->dispatch($event, KernelEvents::VIEW);
in
vendor/symfony/http-kernel/HttpKernel.php
->
handleRaw
(line 81)
{$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());$this->requestStack->push($request);try {return $this->handleRaw($request, $type);} catch (\Exception $e) {if ($e instanceof RequestExceptionInterface) {$e = new BadRequestHttpException($e->getMessage(), $e);}if (false === $catch) {
in
vendor/symfony/http-kernel/Kernel.php
->
handle
(line 201)
// When using the HttpCache, you need to call the method in your front controller instead of relying on the configuration parameter//Request::enableHttpMethodParameterOverride();$request = Request::createFromGlobals();try {$response = $kernel->handle($request, HttpKernelInterface::MASTER_REQUEST, true); //$dev} catch (Exception $e) {if ($dev) {if (property_exists($e, 'xdebug_message')) {$message = $e->xdebug_message;} else {
Logs
No log messages
Stack Trace
RuntimeError |
|---|
Twig\Error\RuntimeError:
Impossible to access an attribute ("metaTitle") on a null variable.
at src/Troika/RealEstateBundle/Resources/views/About/news_item.html.twig:4
at twig_get_attribute()
(var/cache/dev/twig/db/dbd45425926edd0038fad456826b7fe85b68267251d524a7e3b96accb04d3db9.php:72)
at __TwigTemplate_86d331077dc7ce8fb1e564f4580c6d17215efd09d1d044f8e110032f62a32391->block_title()
(vendor/twig/twig/src/Template.php:182)
at Twig\Template->displayBlock()
(var/cache/dev/twig/03/03bf7d28cfa1cd368d82e952ede644e39f786b3510e64009384a644776c3aedb.php:65)
at __TwigTemplate_d4b7182f4c02713aade9853b105ca554fd9c849f0e45ce3805f2876dd6dc71cd->doDisplay()
(vendor/twig/twig/src/Template.php:405)
at Twig\Template->displayWithErrorHandling()
(vendor/twig/twig/src/Template.php:378)
at Twig\Template->display()
(var/cache/dev/twig/db/dbd45425926edd0038fad456826b7fe85b68267251d524a7e3b96accb04d3db9.php:53)
at __TwigTemplate_86d331077dc7ce8fb1e564f4580c6d17215efd09d1d044f8e110032f62a32391->doDisplay()
(vendor/twig/twig/src/Template.php:405)
at Twig\Template->displayWithErrorHandling()
(vendor/twig/twig/src/Template.php:378)
at Twig\Template->display()
(vendor/twig/twig/src/Template.php:390)
at Twig\Template->render()
(vendor/symfony/twig-bridge/TwigEngine.php:54)
at Symfony\Bridge\Twig\TwigEngine->render()
(vendor/symfony/framework-bundle/Controller/ControllerTrait.php:233)
at Symfony\Bundle\FrameworkBundle\Controller\AbstractController->render()
(src/Troika/RealEstateBundle/Controller/DefaultController.php:431)
at Troika\RealEstateBundle\Controller\DefaultController->newsItemAction()
(vendor/symfony/http-kernel/HttpKernel.php:169)
at Symfony\Component\HttpKernel\HttpKernel->handleRaw()
(vendor/symfony/http-kernel/HttpKernel.php:81)
at Symfony\Component\HttpKernel\HttpKernel->handle()
(vendor/symfony/http-kernel/Kernel.php:201)
at Symfony\Component\HttpKernel\Kernel->handle()
(web/app.php:52)
|