diff options
| author | Michael Foster <savetheinternet@tinyboard.org> | 2013-09-18 08:56:04 +1000 |
|---|---|---|
| committer | Michael Foster <savetheinternet@tinyboard.org> | 2013-09-18 08:56:04 +1000 |
| commit | 57e4292e9de44682d128e96397397d72b7bd3ede (patch) | |
| tree | 33f8d2bc77e52557b69d5db78bb9722e2854e1f4 /inc | |
| parent | 3471f7c6684b12b63626af33ae408fd13544cae9 (diff) | |
Improvements to showing post in ban
Diffstat (limited to 'inc')
| -rw-r--r-- | inc/functions.php | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/inc/functions.php b/inc/functions.php index bc159e88..cfde4640 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -634,7 +634,12 @@ function displayBan($ban) { $ban['post']['file'] = 'deleted'; $ban['post']['thumb'] = false; } - $post = new Post($ban['post']); + + if ($ban['post']['thread']) { + $post = new Post($ban['post']); + } else { + $post = new Thread($ban['post'], null, false, false); + } } // Show banned page and exit die( @@ -645,7 +650,8 @@ function displayBan($ban) { 'body' => Element('banned.html', array( 'config' => $config, 'ban' => $ban, - 'post' => isset($post) ? $post->build() : false + 'board' => $board, + 'post' => isset($post) ? $post->build(true) : false ) )) )); |
