diff options
author | Christopher Smith <chris@jalakai.co.uk> | 2014-03-05 22:04:14 +0000 |
---|---|---|
committer | Christopher Smith <chris@jalakai.co.uk> | 2014-03-05 22:04:14 +0000 |
commit | f87b5dbbbad408da775ac4c60ceb9f9666280527 (patch) | |
tree | 53e023772e7ebeb53bad6f13e867483bbed6a683 /inc/template.php | |
parent | 6d2af55dde922ac10a288b4195b1bf338e7bc5a9 (diff) | |
download | rpg-f87b5dbbbad408da775ac4c60ceb9f9666280527.tar.gz rpg-f87b5dbbbad408da775ac4c60ceb9f9666280527.tar.bz2 |
use isset() + ?: or error suppression where value may not be set
Diffstat (limited to 'inc/template.php')
-rw-r--r-- | inc/template.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/inc/template.php b/inc/template.php index 0a6a9e4aa..d9aa8863f 100644 --- a/inc/template.php +++ b/inc/template.php @@ -210,7 +210,7 @@ function tpl_toc($return = false) { } else { $tocok = true; } - $toc = $meta['description']['tableofcontents']; + $toc = isset($meta['description']['tableofcontents']) ? $meta['description']['tableofcontents'] : null; if(!$tocok || !is_array($toc) || !$conf['tocminheads'] || count($toc) < $conf['tocminheads']) { $toc = array(); } |