From 384955402069fde49abecf5cbad63c14bd2239a6 Mon Sep 17 00:00:00 2001 From: chengxl Date: Wed, 14 May 2025 17:11:15 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E4=BC=97=E5=8F=B7=E6=8E=A5=E5=8F=A3?= =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/api/controller/Aiarticle.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/application/api/controller/Aiarticle.php b/application/api/controller/Aiarticle.php index 6927d27..a1bd685 100644 --- a/application/api/controller/Aiarticle.php +++ b/application/api/controller/Aiarticle.php @@ -731,22 +731,22 @@ class Aiarticle extends Base continue; } //更新作者名字 - if(!empty($aUser['author_name'])){ + if(isset($aUser['author_name'])){ $aUpdate = ['localname' => $aUser['author_name']]; Db::name('user')->where('user_id',$value['user_id'])->limit(1)->update($aUpdate); } //更新作者简介和单位 $aUpdateReviewer = []; - if(!empty($aUser['technical'])){ + if(isset($aUser['technical'])){ $aUpdateReviewer['technical'] = $aUser['technical']; } - if(!empty($aUser['introduction'])){ + if(isset($aUser['introduction'])){ $aUpdateReviewer['introduction'] = $aUser['introduction']; } - if(!empty($aUser['company'])){ + if(isset($aUser['company'])){ $aUpdateReviewer['company'] = $aUser['company']; } - if(!empty($aUpdateReviewer)){ + if(isset($aUpdateReviewer)){ if(in_array($value['user_id'], $aUserReviewer)){//更新 Db::name('user_reviewer_info')->where('reviewer_id',$value['user_id'])->limit(1)->update($aUpdateReviewer);