From 62b8fe6ea2ecc3006246c0e5378e01f98e50239c Mon Sep 17 00:00:00 2001 From: Konstantin Komelin Date: Mon, 18 Jul 2016 19:38:10 +0300 Subject: [PATCH] Used array functions to inline arrays. --- src/InsertOnDuplicateKey.php | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/InsertOnDuplicateKey.php b/src/InsertOnDuplicateKey.php index b2c74f8..57beb90 100644 --- a/src/InsertOnDuplicateKey.php +++ b/src/InsertOnDuplicateKey.php @@ -200,15 +200,7 @@ protected static function buildValuesList(array $first) */ protected static function inLineArray(array $data) { - $out = []; - - foreach ($data as $row) { - foreach ($row as $item) { - $out[] = $item; - } - } - - return $out; + return call_user_func_array('array_merge', array_map('array_values', $data)); } /**