* @param bool $throw
* Whether to throw an exception when an error occurs.
*
- * @return string
- * The path to the template.
+ * @return string|false
+ * The path to the template, or false if the template is not found.
*
* @throws \Twig_Error_Loader
* Thrown if a template matching $name cannot be found.
if ($throw) {
throw new \Twig_Error_Loader(sprintf('Unable to find template "%s" in the Drupal theme registry.', $name));
}
+
+ return FALSE;
}
}