From cb68f87ded9a365739080b76e91e00effb3fdf5f Mon Sep 17 00:00:00 2001 From: DiscuzX <153619335@qq.com> Date: Wed, 18 May 2022 11:49:11 +0000 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DPHP8=E4=B8=8B=E5=BA=94?= =?UTF-8?q?=E7=94=A8=E9=A6=96=E6=AC=A1=E4=B8=8B=E8=BD=BD=E6=8A=A5=E9=94=99?= =?UTF-8?q?=E7=9A=84BUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- upload/source/function/function_cloudaddons.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/upload/source/function/function_cloudaddons.php b/upload/source/function/function_cloudaddons.php index f5396d6f4..d43515907 100644 --- a/upload/source/function/function_cloudaddons.php +++ b/upload/source/function/function_cloudaddons.php @@ -160,11 +160,12 @@ function cloudaddons_savemd5($md5file, $end, $md5) { global $_G; parse_str($end, $r); require_once libfile('class/xml'); - $xml = implode('', @file(DISCUZ_ROOT.'./data/addonmd5/'.$md5file.'.xml')); - $array = xml2array($xml); - $ridexists = false; - $data = array(); - if($array['RevisionID']) { + $data = $array = array(); + if(file_exists(DISCUZ_ROOT.'./data/addonmd5/'.$md5file.'.xml')) { + $xml = implode('', @file(DISCUZ_ROOT.'./data/addonmd5/'.$md5file.'.xml')); + $array = xml2array($xml); + } + if(!empty($array['RevisionID'])) { foreach(explode(',', $array['RevisionID']) as $i => $rid) { $sns = explode(',', $array['SN']); $datalines = explode(',', $array['RevisionDateline']); -- Gitee