File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -75,7 +75,7 @@ public function resolveView()
75
75
$ resolver = function ($ view ) {
76
76
$ factory = Container::getInstance ()->make ('view ' );
77
77
78
- return $ factory ->exists ($ view )
78
+ return strlen ( $ view ) <= PHP_MAXPATHLEN && $ factory ->exists ($ view )
79
79
? $ view
80
80
: $ this ->createBladeViewFromString ($ factory , $ view );
81
81
};
Original file line number Diff line number Diff line change @@ -14,6 +14,15 @@ public function test_rendering_blade_string()
14
14
$ this ->assertSame ('Hello Taylor ' , Blade::render ('Hello {{ $name }} ' , ['name ' => 'Taylor ' ]));
15
15
}
16
16
17
+ public function test_rendering_blade_long_maxpathlen_string ()
18
+ {
19
+ $ longString = str_repeat ('a ' , PHP_MAXPATHLEN );
20
+
21
+ $ result = Blade::render ($ longString .'{{ $name }} ' , ['name ' => 'a ' ]);
22
+
23
+ $ this ->assertSame ($ longString .'a ' , $ result );
24
+ }
25
+
17
26
public function test_rendering_blade_component_instance ()
18
27
{
19
28
$ component = new HelloComponent ('Taylor ' );
You can’t perform that action at this time.
0 commit comments