protected function getTemplateName($profiler, $panel)
{
$templates = $this->getTemplateNames($profiler);
if (!isset($templates[$panel])) {
throw new NotFoundHttpException(sprintf('Panel "%s" is not registered.', $panel));
}
return $templates[$panel];
}