From 076235df0bda5b6727f545dd6afb77ed56d37ab1 Mon Sep 17 00:00:00 2001 From: Babak Alizadeh Date: Thu, 6 Mar 2025 01:05:44 +0000 Subject: [PATCH] update --- hesabixCore/src/Command/UpdateSoftwareCommand.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hesabixCore/src/Command/UpdateSoftwareCommand.php b/hesabixCore/src/Command/UpdateSoftwareCommand.php index 8d859e9..c498f83 100644 --- a/hesabixCore/src/Command/UpdateSoftwareCommand.php +++ b/hesabixCore/src/Command/UpdateSoftwareCommand.php @@ -291,10 +291,11 @@ class UpdateSoftwareCommand extends Command private function backupDatabase(): string { $backupFile = $this->backupDir . '/db_backup_' . time() . '.sql'; - $dbUrl = $this->params->get('env(DATABASE_URL)'); // استفاده از ParameterBag با env() + // استفاده از پارامتر Doctrine به جای env(DATABASE_URL) + $dbUrl = $this->params->get('doctrine.dbal.url'); if (!$dbUrl) { - throw new \RuntimeException('DATABASE_URL is not set in the configuration.'); + throw new \RuntimeException('Doctrine database URL is not set in the configuration.'); } $urlParts = parse_url($dbUrl);