Skip to content

Commit

Permalink
Revert "This shouldn't have been here"
Browse files Browse the repository at this point in the history
This reverts commit 02922b9.
  • Loading branch information
brandonkelly committed Oct 2, 2018
1 parent 0d9ed3e commit d38646b
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/Command.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

namespace craft\fixfks;

use craft\helpers\MigrationHelper;

class Command extends \craft\db\Command
{
public function addForeignKey($name, $table, $columns, $refTable, $refColumns, $delete = null, $update = null)
{
// Only add it if it doesn't exist yet
if (!MigrationHelper::doesForeignKeyExist($table, $columns)) {
return parent::addForeignKey($name, $table, $columns, $refTable, $refColumns, $delete, $update);
}

return $this;
}
}

0 comments on commit d38646b

Please sign in to comment.