]> source.dussan.org Git - nextcloud-server.git/commitdiff
Make sure the migrations table schema is always checked
authorJulius Härtl <jus@bitgrid.net>
Wed, 9 Dec 2020 09:10:51 +0000 (10:10 +0100)
committerJulius Härtl <jus@bitgrid.net>
Mon, 14 Dec 2020 10:12:52 +0000 (11:12 +0100)
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Revert "Make sure the migrations table schema is always checked"

This reverts commit 258955ef738a52d9da2ac2fe59466e6093d7e9bc.

Set current vendor during upgrade and perform migrations table change if needed

Signed-off-by: Julius Härtl <jus@bitgrid.net>
lib/private/DB/MigrationService.php
lib/private/Updater.php

index cd0280162d3826bb495c40df83e24ed16d7dba43..33a11589eb41ebbceb52272a5590c37137cd05e0 100644 (file)
@@ -124,6 +124,11 @@ class MigrationService {
                        return false;
                }
 
+               if ($this->connection->tableExists('migrations') && \OC::$server->getConfig()->getAppValue('core', 'vendor', '') !== 'owncloud') {
+                       $this->migrationTableCreated = true;
+                       return false;
+               }
+
                $schema = new SchemaWrapper($this->connection);
 
                /**
index 2b5dce78057e052316918c56534a784926d2bb30..3bf2cb1b6f9589c35e886d0b1eb03b8620f9249e 100644 (file)
@@ -197,6 +197,7 @@ class Updater extends BasicEmitter {
                        isset($allowedPreviousVersions['owncloud'][$majorMinor])
                )) {
                        $currentVendor = 'owncloud';
+                       $this->config->setAppValue('core', 'vendor', $currentVendor);
                }
 
                if ($currentVendor === 'nextcloud') {