8000 merged 2.0 · mshtukin/symfony@5b2bc7d · GitHub
[go: up one dir, main page]

Skip to content

Commit 5b2bc7d

Browse files
committed
merged 2.0
2 parents 74cfd04 + bebdd07 commit 5b2bc7d

File tree

5 files changed

+492
-32
lines changed

5 files changed

+492
-32
lines changed

src/Symfony/Bridge/Twig/Node/TransNode.php

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -55,15 +55,15 @@ public function compile(\Twig_Compiler $compiler)
5555
}
5656

5757
if (null !== $vars) {
58-
$compiler->raw('array_merge(');
59-
$this->compileDefaults($compiler, $defaults);
6058
$compiler
59+
->raw('array_merge(')
60+
->subcompile($defaults)
6161
->raw(', ')
6262
->subcompile($this->getNode('vars'))
6363
->raw(')')
6464
;
6565
} else {
66-
$this->compileDefaults($compiler, $defaults);
66+
$compiler->subcompile($defaults);
6767
}
6868

6969
$compiler
@@ -79,20 +79,6 @@ public function compile(\Twig_Compiler $compiler)
7979
$compiler->raw(");\n");
8080
}
8181

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-
9682
protected function compileString(\Twig_NodeInterface $body, \Twig_Node_Expression_Array $vars)
9783
{
9884
if ($body instanceof \Twig_Node_Expression_Constant) {

src/Symfony/Bundle/FrameworkBundle/Resources/config/schema/symfony-1.0.xsd

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
<xsd:attribute name="ide" type="xsd:string" />
2727
<xsd:attribute name="secret" type="xsd:string" />
2828
<xsd:attribute name="default-locale" type="xsd:string" />
29+
<xsd:attribute name="test" type="xsd:boolean" />
2930
</xsd:complexType>
3031

3132
<xsd:complexType name="form">

src/Symfony/Component/HttpFoundation/ApacheRequest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,6 @@ protected function prepareBaseUrl()
4646
*/
4747
protected function preparePathInfo()
4848
{
49-
return $this->server->get('PATH_INFO');
49+
return $this->server->get('PATH_INFO') ?: substr($this->prepareRequestUri(), strlen($this->prepareBaseUrl())) ?: '/';
5050
}
5151
}

0 commit comments

Comments
 (0)
0