From 6e7cb261e3ad5d46f03751b2b7db29edaff49607 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=80=97=E5=AD=90?= Date: Sat, 10 Dec 2022 13:24:35 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=EF=BC=88=E5=91=BD=E4=BB=A4?= =?UTF-8?q?=E8=A1=8C=EF=BC=89=EF=BC=9A=E4=BF=AE=E5=A4=8D=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E5=88=A4=E6=96=ADbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Console/Commands/Panel.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Console/Commands/Panel.php b/app/Console/Commands/Panel.php index 86a4bf68..bcd359d5 100644 --- a/app/Console/Commands/Panel.php +++ b/app/Console/Commands/Panel.php @@ -35,7 +35,7 @@ class Panel extends Command public function handle() { // 检测是否以root用户运行 - if (shell_exec('whoami') != 'root') { + if (trim(shell_exec('whoami')) != 'root') { $this->error('耗子Linux面板:请以root用户运行'); return 1; }