Skip to content

Commit 69a0faf

Browse files
committed
use the parseFile() method of the YAML parser
1 parent 67a37ef commit 69a0faf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Loader/YamlFileLoader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -654,7 +654,7 @@ protected function loadFile($file)
654654
}
655655

656656
try {
657-
$configuration = $this->yamlParser->parse(file_get_contents($file), Yaml::PARSE_CONSTANT | Yaml::PARSE_CUSTOM_TAGS);
657+
$configuration = $this->yamlParser->parseFile($file, Yaml::PARSE_CONSTANT | Yaml::PARSE_CUSTOM_TAGS);
658658
} catch (ParseException $e) {
659659
throw new InvalidArgumentException(sprintf('The file "%s" does not contain valid YAML.', $file), 0, $e);
660660
}

0 commit comments

Comments
 (0)