minor #14762 InvalidResourceException file name (DancZer)

This PR was submitted for the 2.7 branch but it was merged into the 2.3 branch instead (closes #14762).

Discussion
----------

InvalidResourceException file name

Added filen ame to the InvalidResourceException,

Commits
-------

2e04e23 InvalidResourceException file name
This commit is contained in:
Fabien Potencier 2015-05-28 22:42:23 +02:00
commit afd0b105a1

View File

@ -114,7 +114,7 @@ class XliffFileLoader implements LoaderInterface
$source = str_replace('http://www.w3.org/2001/xml.xsd', $location, $source);
if (!@$dom->schemaValidateSource($source)) {
throw new InvalidResourceException(implode("\n", $this->getXmlErrors($internalErrors)));
throw new InvalidResourceException(sprintf('Invalid resource provided: "%s"; Errors: %s', $file, implode("\n", $this->getXmlErrors($internalErrors))));
}
$dom->normalizeDocument();