Skip to content

Commit

Permalink
FIX HTTPBulkToolsResponse.addSuccessRecords() fn
Browse files Browse the repository at this point in the history
This function was trying to merge 2 arrays with PHP fn `array_push()`
which was failing if the second parameter was array as well. This fix
replaces `array_push()` with `array_merge()` fn.

Resolves #187
  • Loading branch information
pschiffe committed Mar 4, 2024
1 parent bdefd14 commit 379fda0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/BulkTools/HTTPBulkToolsResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ public function addSuccessRecord($record)
*/
public function addSuccessRecords(SS_List $records)
{
array_push($this->successRecords, $records->toArray());
$this->successRecords = array_merge($this->successRecords, $records->toArray());
return $this;
}

Expand Down

0 comments on commit 379fda0

Please sign in to comment.