summaryrefslogtreecommitdiff
path: root/db/migrations
diff options
context:
space:
mode:
Diffstat (limited to 'db/migrations')
-rw-r--r--db/migrations/ChangesReferences.php1
-rw-r--r--db/migrations/Reference.php1
2 files changed, 2 insertions, 0 deletions
diff --git a/db/migrations/ChangesReferences.php b/db/migrations/ChangesReferences.php
index 1e7a5f10..b5b39ac3 100644
--- a/db/migrations/ChangesReferences.php
+++ b/db/migrations/ChangesReferences.php
@@ -31,6 +31,7 @@ trait ChangesReferences
$table->foreign($reference->column)
->references($targetColumn)->on($targetTable)
+ ->onUpdate('cascade')
->onDelete('cascade');
}
);
diff --git a/db/migrations/Reference.php b/db/migrations/Reference.php
index 4c35b59b..719bee76 100644
--- a/db/migrations/Reference.php
+++ b/db/migrations/Reference.php
@@ -31,6 +31,7 @@ trait Reference
$table->foreign($fromColumn)
->references('id')->on($targetTable)
+ ->onUpdate('cascade')
->onDelete('cascade');
}
}