ソースを参照

Correccion para las migraciones

gabriel 7 年 前
コミット
0d18a3ef1d
1 ファイル変更5 行追加6 行削除
  1. 5 6
      Migrations/MigrationsBase.php

+ 5 - 6
Migrations/MigrationsBase.php

@@ -224,9 +224,9 @@ class MigrationsBase extends AbstractMigration implements ContainerAwareInterfac
                     $this->createUpdates($value[MigrationsBase::UPDATE]);
                 } else if (strtoupper($key) === MigrationsBase::DELETE) {
                     $this->createDeletes($value[MigrationsBase::DELETE]);
-		}else{
-			die("Valor no esperado");
-		}
+                } else {
+                    die("Valor no esperado");
+                }
             }
         }
     }
@@ -493,8 +493,7 @@ class MigrationsBase extends AbstractMigration implements ContainerAwareInterfac
      */
     public function executeSQL($sql, $type, $arrayPrepare = null)
     {
-	$this->addSql($sql, (array)$arrayPrepare);
-
+        $this->connection->executeUpdate($sql, (array)$arrayPrepare);
         $this->sumLine();
     }
 
@@ -747,7 +746,7 @@ class MigrationsBase extends AbstractMigration implements ContainerAwareInterfac
             foreach ($resp as $key => $value) {
                 if (isset($value["AUTO_INCREMENT"])) {
                     $autoIncrement = $value["AUTO_INCREMENT"];
-}
+                }
             }
         } catch (\Throwable $e) {
         }