From 261c3a021719a70a9fbb0b39823d7abcb9300413 Mon Sep 17 00:00:00 2001 From: Lufei Date: Thu, 13 Oct 2022 09:37:41 +0800 Subject: [PATCH] * Fix GH-92: Uncaught TypeError: Unsupported operand types: array + null. --- module/block/control.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/module/block/control.php b/module/block/control.php index 668d64ac3a..9095efb3cd 100755 --- a/module/block/control.php +++ b/module/block/control.php @@ -488,7 +488,8 @@ class block extends control return true; } - $blocks = json_decode($blocks, true); + $blocks = json_decode($blocks, true); + if(empty($blocks)) $blocks = array(); $blockPairs = array('' => '') + $blocks; echo '
';