Skip to content

Commit e795fc9

Browse files
authored
fix: don't convert paths with realpath()
1 parent 636e2e6 commit e795fc9

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

bin/swoole-server

+2-3
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use Swoole\Timer;
1313

1414
ini_set('display_errors', 'stderr');
1515

16-
$basePath = realpath(getenv('APP_RELEASE_BIN_DIR'));
16+
$basePath = getenv('APP_RELEASE_BIN_DIR');
1717

1818
require_once $basePath . '/../src/Stream.php';
1919

@@ -51,9 +51,8 @@ $timerTable = require $basePath . '/createSwooleTimerTable.php';
5151
|
5252
*/
5353

54-
$server->on('beforereload', function (Server $server) use (&$basePath) {
54+
$server->on('beforereload', function (Server $server) {
5555
clearstatcache(true);
56-
$basePath = realpath(getenv('APP_RELEASE_BIN_DIR'));
5756
});
5857

5958
$server->on('start', fn (Server $server) => $bootstrap($serverState) && (new OnServerStart(

0 commit comments

Comments
 (0)