display.php: handle thread already having an array (PHP 8.0 fix)

This commit is contained in:
Zankaria 2024-07-13 11:39:29 +02:00
parent 27726d6c2b
commit 0c8ea349ca

View file

@ -364,8 +364,9 @@ class Thread {
$this->{$key} = $value;
}
if (isset($this->files))
$this->files = @json_decode($this->files);
if (isset($this->files) && !is_array($this->files)) {
$this->files = json_decode($this->files);
}
$this->subject = utf8tohtml($this->subject);
$this->name = utf8tohtml($this->name);