Start using webmozart/pathutil for joining paths (#4287)

This commit is contained in:
Dylan T
2021-06-29 19:40:43 +01:00
committed by GitHub
parent aee7b03c1d
commit 32d7b1e6af
31 changed files with 252 additions and 172 deletions

View File

@ -24,7 +24,7 @@ declare(strict_types=1);
namespace pocketmine\scheduler;
use pocketmine\MemoryManager;
use const DIRECTORY_SEPARATOR;
use Webmozart\PathUtil\Path;
/**
* Task used to dump memory from AsyncWorkers
@ -46,7 +46,7 @@ class DumpWorkerMemoryTask extends AsyncTask{
public function onRun() : void{
MemoryManager::dumpMemory(
$this->worker,
$this->outputFolder . DIRECTORY_SEPARATOR . "AsyncWorker#" . $this->worker->getAsyncWorkerId(),
Path::join($this->outputFolder, "AsyncWorker#" . $this->worker->getAsyncWorkerId()),
$this->maxNesting,
$this->maxStringSize,
new \PrefixedLogger($this->worker->getLogger(), "Memory Dump")