aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/phpbb')
-rw-r--r--phpBB/phpbb/template/context.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/phpBB/phpbb/template/context.php b/phpBB/phpbb/template/context.php
index de583d3224..2ba6d185ad 100644
--- a/phpBB/phpbb/template/context.php
+++ b/phpBB/phpbb/template/context.php
@@ -274,6 +274,11 @@ class context
{
$name = substr($blocks[$i], 0, $pos);
+ if (empty($block[$name]))
+ {
+ return array();
+ }
+
if (strpos($blocks[$i], '[]') === $pos)
{
$index = count($block[$name]) - 1;
@@ -286,6 +291,11 @@ class context
else
{
$name = $blocks[$i];
+ if (empty($block[$name]))
+ {
+ return array();
+ }
+
$index = count($block[$name]) - 1;
}
$block = $block[$name];