public function Twig_Loader_Array::isFresh in Translation template extractor 7.3
Same name and namespace in other branches
- 6.3 vendor/Twig/Loader/Array.php \Twig_Loader_Array::isFresh()
Returns true if the template is still fresh.
Parameters
string $name The template name:
int $time Timestamp of the last modification time of the: cached template
Return value
bool true if the template is fresh, false otherwise
Throws
Twig_Error_Loader When $name is not found
Overrides Twig_LoaderInterface::isFresh
File
- vendor/
Twig/ Loader/ Array.php, line 86
Class
- Twig_Loader_Array
- Loads a template from an array.
Code
public function isFresh($name, $time) {
$name = (string) $name;
if (!isset($this->templates[$name])) {
throw new Twig_Error_Loader(sprintf('Template "%s" is not defined.', $name));
}
return true;
}