private function setPaymentOptionsReceiverDetails($receivers)
    {
        return collect($receivers)->map(function ($receiver) {
            $item = [];

            $item['receiver'] = [
                'email' => $receiver['email'],
            ];

            $item['invoiceData']['item'] = collect($receiver['invoice_data'])->map(function ($invoice) {
                return $invoice;
            })->toArray();

            $item['description'] = $receiver['description'];

            return $item;
        })->toArray();
    }
private function setPaymentOptionsReceiverDetails($receivers)
    {
        return collect($receivers)->map(function ($receiver) {
            $item = [];

            $item['receiver'] = [
                'email' => $receiver['email'],
            ];

            $item['invoiceData']['item'] = collect($receiver['invoice_data'])->map(function ($invoice) {
                return $invoice;
            })->toArray();

            $item['description'] = $receiver['description'];

            return $item;
        })->toArray();
    }
private function setPaymentOptionsReceiverDetails ( $ receivers ) { return collect ( $ receivers ) -> map ( function ( $ receiver ) { $ item = [ ] ; $ item [ 'receiver' ] = [ 'email' => $ receiver [ 'email' ] , ] ; $ item [ 'invoiceData' ] [ 'item' ] = collect ( $ receiver [ 'invoice_data' ] ) -> map ( function ( $ invoice ) { return $ invoice ; } ) -> toArray ( ) ; $ item [ 'description' ] = $ receiver [ 'description' ] ; return $ item ; } ) -> toArray ( ) ; }
Set receiver details for SetPaymentOptions.

@param array $receivers

@return array
Set receiver details for SetPaymentOptions .