mavinoo / laravelBatch

insert batch and update batch in laravel
MIT License
571 stars 118 forks source link

the new releases after 2.3.1 has a bug in file Batch.php - Insert Function #90

Closed thaifanisalla closed 2 years ago

thaifanisalla commented 2 years ago

in line (https://github.com/mavinoo/laravelBatch/blob/126f077dec4ecabb67331694e71bf28b427daa60/src/Batch.php#L274)

in release 2.3.1 and earlier this line was

if (count($columns) !== count($values[0])) {  

in the latest release it changes to

if (count($columns) !== count(current($values))) {

and it cause a bug for us when send array values of rows
please revert it Or fix it

maciej-kosiedowski commented 2 years ago

@mavinoo Could you create new Release with https://github.com/mavinoo/laravelBatch/commit/126f077dec4ecabb67331694e71bf28b427daa60 included ?

mavinoo commented 2 years ago

reinstall package or update package to 2.3.4

batch-insert