File tree Expand file tree Collapse file tree 5 files changed +492
-32
lines changed
Bundle/FrameworkBundle/Resources/config/schema
tests/Symfony/Tests/Component/HttpFoundation Expand file tree Collapse file tree 5 files changed +492
-32
lines changed Original file line number Diff line number Diff line change @@ -55,15 +55,15 @@ public function compile(\Twig_Compiler $compiler)
55
55
}
56
56
57
57
if (null !== $ vars ) {
58
- $ compiler ->raw ('array_merge( ' );
59
- $ this ->compileDefaults ($ compiler , $ defaults );
60
58
$ compiler
59
+ ->raw ('array_merge( ' )
60
+ ->subcompile ($ defaults )
61
61
->raw (', ' )
62
62
->subcompile ($ this ->getNode ('vars ' ))
63
63
->raw (') ' )
64
64
;
65
65
} else {
66
- $ this -> compileDefaults ( $ compiler , $ defaults );
66
+ $ compiler -> subcompile ( $ defaults );
67
67
}
68
68
69
69
$ compiler
@@ -79,20 +79,6 @@ public function compile(\Twig_Compiler $compiler)
79
79
$ compiler ->raw ("); \n" );
80
80
}
81
81
82
- protected function compileDefaults (\Twig_Compiler $ compiler , \Twig_Node_Expression_Array $ defaults )
83
- {
84
- $ compiler ->raw ('array( ' );
85
- foreach ($ defaults as $ name => $ default ) {
86
- $ compiler
87
- ->repr ($ name )
88
- ->raw (' => ' )
89
- ->subcompile ($ default )
90
- ->raw (', ' )
91
- ;
92
- }
93
- $ compiler ->raw (') ' );
94
- }
95
-
96
82
protected function compileString (\Twig_NodeInterface $ body , \Twig_Node_Expression_Array $ vars )
97
83
{
98
84
if ($ body instanceof \Twig_Node_Expression_Constant) {
Original file line number Diff line number Diff line change 26
26
<xsd : attribute name =" ide" type =" xsd:string" />
27
27
<xsd : attribute name =" secret" type =" xsd:string" />
28
28
<xsd : attribute name =" default-locale" type =" xsd:string" />
29
+ <xsd : attribute name =" test" type =" xsd:boolean" />
29
30
</xsd : complexType >
30
31
31
32
<xsd : complexType name =" form" >
Original file line number Diff line number Diff line change @@ -46,6 +46,6 @@ protected function prepareBaseUrl()
46
46
*/
47
47
protected function preparePathInfo ()
48
48
{
49
- return $ this ->server ->get ('PATH_INFO ' );
49
+ return $ this ->server ->get ('PATH_INFO ' ) ?: substr ( $ this -> prepareRequestUri (), strlen ( $ this -> prepareBaseUrl ())) ?: ' / ' ;
50
50
}
51
51
}
You can’t perform that action at this time.
0 commit comments