File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed
src/Symfony/Component/Intl/Data/Bundle/Reader Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -32,27 +32,24 @@ public function read($path, $locale)
32
32
33
33
if (!file_exists ($ fileName )) {
34
34
throw new ResourceBundleNotFoundException (sprintf (
35
- 'The resource bundle "%s/%s.json" does not exist. ' ,
36
- $ path ,
37
- $ locale
35
+ 'The resource bundle "%s" does not exist. ' ,
36
+ $ fileName
38
37
));
39
38
}
40
39
41
40
if (!is_file ($ fileName )) {
42
41
throw new RuntimeException (sprintf (
43
- 'The resource bundle "%s/%s.json" is not a file. ' ,
44
- $ path ,
45
- $ locale
42
+ 'The resource bundle "%s" is not a file. ' ,
43
+ $ fileName
46
44
));
47
45
}
48
46
49
47
$ data = json_decode (file_get_contents ($ fileName ), true );
50
48
51
49
if (null === $ data ) {
52
50
throw new RuntimeException (sprintf (
53
- 'The resource bundle "%s/%s.json" contains invalid JSON: %s ' ,
54
- $ path ,
55
- $ locale ,
51
+ 'The resource bundle "%s" contains invalid JSON: %s ' ,
52
+ $ fileName ,
56
53
self ::getLastJsonError ()
57
54
));
58
55
}
You can’t perform that action at this time.
0 commit comments