Skip to content
Permalink
Browse files

Always cast an array

  • Loading branch information...
HavokInspiration committed Jun 16, 2015
1 parent c0a96b6 commit 8b45acb4c717a39615e5a94e5c78fafa785655c5
Showing with 1 addition and 5 deletions.
  1. +1 −5 src/Database/Schema/Table.php
@@ -518,12 +518,8 @@ public function addConstraint($name, $attrs)
$attrs['columns']
);
if (is_string($this->_constraints[$name]['references'][1])) {
$this->_constraints[$name]['references'][1] = [$this->_constraints[$name]['references'][1]];
}
$this->_constraints[$name]['references'][1] = array_merge(
$this->_constraints[$name]['references'][1],
(array)$this->_constraints[$name]['references'][1],
[$attrs['references'][1]]
);
return $this;

0 comments on commit 8b45acb

Please sign in to comment.
You can’t perform that action at this time.