fix: also add `version` to `OC.config` during setup

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
pull/54497/head
Ferdinand Thiessen 2025-08-19 17:39:36 +07:00 committed by nextcloud-command
parent 7d73be6bdd
commit 4b2fcac882
1 changed files with 4 additions and 0 deletions

@ -12,6 +12,7 @@ use OC\Setup;
use OCP\IInitialStateService;
use OCP\IURLGenerator;
use OCP\Server;
use OCP\ServerVersion;
use OCP\Template\ITemplateManager;
use OCP\Util;
use Psr\Log\LoggerInterface;
@ -25,6 +26,7 @@ class SetupController {
protected ITemplateManager $templateManager,
protected IInitialStateService $initialStateService,
protected IURLGenerator $urlGenerator,
protected ServerVersion $serverVersion,
) {
$this->autoConfigFile = \OC::$configDir . 'autoconfig.php';
}
@ -80,6 +82,8 @@ class SetupController {
'dbtype' => '',
'hasAutoconfig' => false,
'serverRoot' => \OC::$SERVERROOT,
'version' => implode('.', $this->serverVersion->getVersion()),
'versionstring' => $this->serverVersion->getVersionString(),
];
$parameters = array_merge($defaults, $post);