fix Merge branch '2.7' into 2.8 JsonFileLoader
This commit is contained in:
parent
ae470cdf14
commit
692deff7b0
@ -25,14 +25,6 @@ class JsonFileLoader extends FileLoader
|
||||
*/
|
||||
protected function loadResource($resource)
|
||||
{
|
||||
if (!stream_is_local($resource)) {
|
||||
throw new InvalidResourceException(sprintf('This is not a local file "%s".', $resource));
|
||||
}
|
||||
|
||||
if (!file_exists($resource)) {
|
||||
throw new NotFoundResourceException(sprintf('File "%s" not found.', $resource));
|
||||
}
|
||||
|
||||
$messages = array();
|
||||
if ($data = file_get_contents($resource)) {
|
||||
$messages = json_decode($data, true);
|
||||
|
Reference in New Issue
Block a user