diff options
author | Simon Holywell <[email protected]> | 2016-12-14 14:22:01 +1000 |
---|---|---|
committer | GitHub <[email protected]> | 2016-12-14 14:22:01 +1000 |
commit | bd4bc89304f0cc72e6447b7581f2bb2f090106a9 (patch) | |
tree | 670276406309dc1dc8eeb0d6c53964b33c50e22b /idiorm.php | |
parent | 391eb8aa27b107a79286e3c21f5f30580f20ae5e (diff) | |
parent | 2ff8cd553598ae6fd0f516696489b4552068255d (diff) |
Merge pull request #235 from lrlopez/compound_key_fix
Fix autoincremented compound keys inserts
Diffstat (limited to 'idiorm.php')
-rw-r--r-- | idiorm.php | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -2101,7 +2101,7 @@ // if the primary key is compound, assign the last inserted id // to the first column if (is_array($column)) { - $column = array_slice($column, 0, 1); + $column = reset($column); } $this->_data[$column] = $db->lastInsertId(); } |