]> source.dussan.org Git - nextcloud-server.git/commitdiff
Use the correct property for connection object
authorBart Visscher <bartv@thisnet.nl>
Sun, 17 Mar 2013 13:32:01 +0000 (14:32 +0100)
committerBart Visscher <bartv@thisnet.nl>
Sun, 17 Mar 2013 13:32:01 +0000 (14:32 +0100)
lib/db.php
lib/setup.php

index 518fcc56a09eef219db987426b3a1d6ebca63545..49eeeea430cedb1e2c5649afa3e0e973745e7088 100644 (file)
@@ -308,7 +308,7 @@ class OC_DB {
         */
        public static function getDbStructure( $file, $mode=MDB2_SCHEMA_DUMP_STRUCTURE) {
                self::connectDoctrine();
-               return OC_DB_Schema::getDbStructure(self::$connection, $file);
+               return OC_DB_Schema::getDbStructure(self::$DOCTRINE, $file);
        }
 
        /**
@@ -320,7 +320,7 @@ class OC_DB {
         */
        public static function createDbFromStructure( $file ) {
                self::connectDoctrine();
-               return OC_DB_Schema::createDbFromStructure(self::$connection, $file);
+               return OC_DB_Schema::createDbFromStructure(self::$DOCTRINE, $file);
                /* FIXME: use CURRENT_TIMESTAMP for all databases. mysql supports it as a default for DATETIME since 5.6.5 [1]
                 * as a fallback we could use <default>0000-01-01 00:00:00</default> everywhere
                 * [1] http://bugs.mysql.com/bug.php?id=27645
@@ -343,7 +343,7 @@ class OC_DB {
        public static function updateDbFromStructure($file) {
                self::connectDoctrine();
                try {
-                       $result = OC_DB_Schema::updateDbFromStructure(self::$connection, $file);
+                       $result = OC_DB_Schema::updateDbFromStructure(self::$DOCTRINE, $file);
                } catch (Exception $e) {
                        OC_Log::write('core', 'Failed to update database structure ('.$e.')', OC_Log::FATAL);
                        throw $e;
@@ -543,7 +543,7 @@ class OC_DB {
         */
        public static function dropTable($tableName) {
                self::connectDoctrine();
-               OC_DB_Schema::dropTable(self::$connection, $tableName);
+               OC_DB_Schema::dropTable(self::$DOCTRINE, $tableName);
        }
 
        /**
@@ -552,7 +552,7 @@ class OC_DB {
         */
        public static function removeDBStructure($file) {
                self::connectDoctrine();
-               OC_DB_Schema::removeDBStructure(self::$connection, $file);
+               OC_DB_Schema::removeDBStructure(self::$DOCTRINE, $file);
        }
 
        /**
@@ -561,7 +561,7 @@ class OC_DB {
         */
        public static function replaceDB( $file ) {
                self::connectDoctrine();
-               OC_DB_Schema::replaceDB(self::$connection, $file);
+               OC_DB_Schema::replaceDB(self::$DOCTRINE, $file);
        }
 
        /**
index 8814447f52feb4c78edc2804047af44f62990e7a..bee70e7ebcc613a78dc03a0bcdc551832e765684 100644 (file)
@@ -178,7 +178,7 @@ class OC_Setup {
                                }
                        }
                        else {
-                               //delete the old sqlite database first, might cause infinte loops otherwise
+                               //delete the old sqlite database first, might cause infinite loops otherwise
                                if(file_exists("$datadir/owncloud.db")) {
                                        unlink("$datadir/owncloud.db");
                                }