From 51aceefb78a2e6910fde885af538ed57cc5d2ff5 Mon Sep 17 00:00:00 2001 From: wangxuepeng Date: Mon, 9 Oct 2023 05:45:45 +0000 Subject: [PATCH] * Refactor actionModel::deleteByType. --- module/action/model.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/module/action/model.php b/module/action/model.php index 836554e478..61f04dca2b 100755 --- a/module/action/model.php +++ b/module/action/model.php @@ -1256,11 +1256,13 @@ class actionModel extends model * * @param string $objectType * @access public - * @return void + * @return bool */ - public function deleteByType(string $objectType) + public function deleteByType(string $objectType): bool { $this->dao->delete()->from(TABLE_ACTION)->where('objectType')->eq($objectType)->exec(); + + return !dao::isError(); } /**