1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

Merge branch '3.1.x'

This commit is contained in:
Joas Schilling
2015-05-16 13:40:07 +02:00
9 changed files with 167 additions and 10 deletions

View File

@@ -117,7 +117,8 @@ class token_storage implements TokenStorageInterface
{
$service = $this->get_service_name_for_db($service);
if ($this->cachedToken) {
if ($this->cachedToken)
{
return true;
}
@@ -232,7 +233,8 @@ class token_storage implements TokenStorageInterface
{
$service = $this->get_service_name_for_db($service);
if ($this->cachedToken instanceof TokenInterface) {
if ($this->cachedToken instanceof TokenInterface)
{
return $this->cachedToken;
}

View File

@@ -115,7 +115,8 @@ class loader extends \Twig_Loader_Filesystem
// If this is in the cache we can skip the entire process below
// as it should have already been validated
if (isset($this->cache[$name])) {
if (isset($this->cache[$name]))
{
return $this->cache[$name];
}

View File

@@ -31,7 +31,8 @@ class definenode extends \Twig_Node
{
$compiler->addDebugInfo($this);
if ($this->getAttribute('capture')) {
if ($this->getAttribute('capture'))
{
$compiler
->write("ob_start();\n")
->subcompile($this->getNode('value'))

View File

@@ -47,7 +47,8 @@ class includephp extends \Twig_Node
return;
}
if ($this->getAttribute('ignore_missing')) {
if ($this->getAttribute('ignore_missing'))
{
$compiler
->write("try {\n")
->indent()
@@ -76,7 +77,8 @@ class includephp extends \Twig_Node
->write("}\n")
;
if ($this->getAttribute('ignore_missing')) {
if ($this->getAttribute('ignore_missing'))
{
$compiler
->outdent()
->write("} catch (\Twig_Error_Loader \$e) {\n")

View File

@@ -33,7 +33,8 @@ class defineparser extends \Twig_TokenParser
$name = $this->parser->getExpressionParser()->parseExpression();
$capture = false;
if ($stream->test(\Twig_Token::OPERATOR_TYPE, '=')) {
if ($stream->test(\Twig_Token::OPERATOR_TYPE, '='))
{
$stream->next();
$value = $this->parser->getExpressionParser()->parseExpression();
@@ -45,7 +46,9 @@ class defineparser extends \Twig_TokenParser
}
$stream->expect(\Twig_Token::BLOCK_END_TYPE);
} else {
}
else
{
$capture = true;
$stream->expect(\Twig_Token::BLOCK_END_TYPE);

View File

@@ -31,7 +31,8 @@ class includephp extends \Twig_TokenParser
$stream = $this->parser->getStream();
$ignoreMissing = false;
if ($stream->test(\Twig_Token::NAME_TYPE, 'ignore')) {
if ($stream->test(\Twig_Token::NAME_TYPE, 'ignore'))
{
$stream->next();
$stream->expect(\Twig_Token::NAME_TYPE, 'missing');