diff options
| author | czaks <marcin@6irc.net> | 2016-02-09 12:37:03 +0100 |
|---|---|---|
| committer | czaks <marcin@6irc.net> | 2016-02-09 12:37:03 +0100 |
| commit | c53f13bf90716461780fef0a2b4b6e2b5b3cb002 (patch) | |
| tree | 5cd18f303da0b0e6fdc87f175adf5f5f86d881e2 /inc/display.php | |
| parent | fe66c51a19920378885fb790d341cc50c933b046 (diff) | |
| parent | 028fd3df15b2e2edc96c5b84156b0b039ea16562 (diff) | |
Merge branch 'master' of https://github.com/vichan-devel/vichan
Diffstat (limited to 'inc/display.php')
| -rw-r--r-- | inc/display.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/inc/display.php b/inc/display.php index 65525ab9..90cf3434 100644 --- a/inc/display.php +++ b/inc/display.php @@ -354,7 +354,7 @@ class Post { } if (isset($this->files) && $this->files) - $this->files = json_decode($this->files); + $this->files = @json_decode($this->files); $this->subject = utf8tohtml($this->subject); $this->name = utf8tohtml($this->name); @@ -404,7 +404,7 @@ class Thread { } if (isset($this->files)) - $this->files = json_decode($this->files); + $this->files = @json_decode($this->files); $this->subject = utf8tohtml($this->subject); $this->name = utf8tohtml($this->name); @@ -453,7 +453,8 @@ class Thread { event('show-thread', $this); - $built = Element('post_thread.html', array('config' => $config, 'board' => $board, 'post' => &$this, 'index' => $index, 'hasnoko50' => $hasnoko50, 'isnoko50' => $isnoko50, 'mod' => $this->mod)); + $file = ($index && $config['file_board']) ? 'post_thread_fileboard.html' : 'post_thread.html'; + $built = Element($file, array('config' => $config, 'board' => $board, 'post' => &$this, 'index' => $index, 'hasnoko50' => $hasnoko50, 'isnoko50' => $isnoko50, 'mod' => $this->mod)); return $built; } |
