No longer bubble tag exceptions to the top

When a tag has an invalid component to it it would cause a whole file to fail
to parse. Instead we should consider invalid tags a nuisance but not worth
breaking the whole parsing over.

In this change I have added a try..catch that will prevent invalid tags from
breaking the whole parsing process.
This commit is contained in:
Mike van Riel
2019-06-15 22:45:01 +02:00
parent 48351665a8
commit 8fcadfe5f8
+4
View File
@@ -191,7 +191,11 @@ final class StandardTagFactory implements TagFactory
$this->getServiceLocatorWithDynamicParameters($context, $name, $body)
);
try {
return call_user_func_array([$handlerClassName, 'create'], $arguments);
} catch (\InvalidArgumentException $e) {
return null;
}
}
/**