From 7fa0d6674d6c1aaa985a9f8513ccecdaa6256f2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Wed, 11 Nov 2020 10:59:12 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- System/Snowflake.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/System/Snowflake.php b/System/Snowflake.php index e70510b5..f23311f0 100644 --- a/System/Snowflake.php +++ b/System/Snowflake.php @@ -230,7 +230,9 @@ class Snowflake */ public static function getMasterPid() { - return file_get_contents(storage('socket.sock')); + $default = APP_PATH . 'storage/server.pid'; + $server = Config::get('settings.pid_file', $default); + return file_get_contents($server); }