@@ -1094,12 +1094,12 @@ private function registerTranslatorConfiguration(array $config, ContainerBuilder
10941094$ defaultDir =$ container ->getParameterBag ()->resolveValue ($ config ['default_path ' ]);
10951095$ rootDir =$ container ->getParameter ('kernel.root_dir ' );
10961096foreach ($ container ->getParameter ('kernel.bundles_metadata ' )as $ name =>$ bundle ) {
1097- if (\file_exists ($ dir =$ bundle ['path ' ].'/Resources/translations ' )) {
1097+ if (\is_dir ($ dir =$ bundle ['path ' ].'/Resources/translations ' )) {
10981098$ dirs [] =$ dir ;
10991099 }else {
11001100$ nonExistingDirs [] =$ dir ;
11011101 }
1102- if (\file_exists ($ dir =$ rootDir .sprintf ('/Resources/%s/translations ' ,$ name ))) {
1102+ if (\is_dir ($ dir =$ rootDir .sprintf ('/Resources/%s/translations ' ,$ name ))) {
11031103 @trigger_error (sprintf ('Translations directory "%s" is deprecated since Symfony 4.2, use "%s" instead. ' ,$ dir ,$ defaultDir ),E_USER_DEPRECATED );
11041104$ dirs [] =$ dir ;
11051105 }else {
@@ -1108,7 +1108,7 @@ private function registerTranslatorConfiguration(array $config, ContainerBuilder
11081108 }
11091109
11101110foreach ($ config ['paths ' ]as $ dir ) {
1111- if (\file_exists ($ dir )) {
1111+ if (\is_dir ($ dir )) {
11121112$ dirs [] =$ transPaths [] =$ dir ;
11131113 }else {
11141114throw new \UnexpectedValueException (sprintf ('%s defined in translator.paths does not exist or is not a directory ' ,$ dir ));
@@ -1123,13 +1123,13 @@ private function registerTranslatorConfiguration(array $config, ContainerBuilder
11231123$ container ->getDefinition ('console.command.translation_update ' )->replaceArgument (6 ,$ transPaths );
11241124 }
11251125
1126- if (\file_exists ($ defaultDir )) {
1126+ if (\is_dir ($ defaultDir )) {
11271127$ dirs [] =$ defaultDir ;
11281128 }else {
11291129$ nonExistingDirs [] =$ defaultDir ;
11301130 }
11311131
1132- if (\file_exists ($ dir =$ rootDir .'/Resources/translations ' )) {
1132+ if (\is_dir ($ dir =$ rootDir .'/Resources/translations ' )) {
11331133if ($ dir !==$ defaultDir ) {
11341134 @trigger_error (sprintf ('Translations directory "%s" is deprecated since Symfony 4.2, use "%s" instead. ' ,$ dir ,$ defaultDir ),E_USER_DEPRECATED );
11351135 }