Place world conversion backups in <pwd>/backups/worlds instead of <pwd>/world_conversion_backups

This commit is contained in:
Dylan K. Taylor 2021-03-17 01:21:11 +00:00
parent fe3b493cdb
commit 5a59afbe2c
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D

View File

@ -51,6 +51,7 @@ use function random_int;
use function round;
use function sprintf;
use function trim;
use const DIRECTORY_SEPARATOR;
class WorldManager{
/** @var string */
@ -224,7 +225,7 @@ class WorldManager{
}
$this->server->getLogger()->notice("Upgrading world \"$name\" to new format. This may take a while.");
$converter = new FormatConverter($provider, $this->providerManager->getDefault(), $this->server->getDataPath() . "world_conversion_backups", $this->server->getLogger());
$converter = new FormatConverter($provider, $this->providerManager->getDefault(), $this->server->getDataPath() . "backups" . DIRECTORY_SEPARATOR . "worlds", $this->server->getLogger());
$provider = $converter->execute();
$this->server->getLogger()->notice("Upgraded world \"$name\" to new format successfully. Backed up pre-conversion world at " . $converter->getBackupPath());