From bd81c04a29145f09ea41176917b5ddb9e873cb3e Mon Sep 17 00:00:00 2001 From: reshmabidikar Date: Wed, 13 Dec 2023 14:08:01 +0530 Subject: [PATCH] Fix for integration test failure --- lib/killbill_client/models/account.rb | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/lib/killbill_client/models/account.rb b/lib/killbill_client/models/account.rb index 5fff5bd..70d0347 100644 --- a/lib/killbill_client/models/account.rb +++ b/lib/killbill_client/models/account.rb @@ -144,12 +144,13 @@ def bundles(options = {}) end def invoices(options = {}) + params_hash = options.delete(:params) + options_to_merge = params_hash.nil? ? {} : params_hash + merged_options = { :includeInvoiceComponents => true }.merge(options_to_merge) self.class.get "#{KILLBILL_API_ACCOUNTS_PREFIX}/#{account_id}/invoices", - { - :includeInvoiceComponents => true - }.merge(options.delete(:params)), - options, - Invoice + merged_options, + options, + Invoice end def migration_invoices(options = {})