Skip to content

Commit b06262b

Browse files
committedAug 6, 2018
Pull the Subscription ID from the 2nd item in the reference string
At some point the CyberSource gateway was updated to pull it from the 6th item, but our records are still storing it on the 2nd. Probably update/migrate all of our strings soon to make them match ActiveMerhant master.
1 parent 3d6b3b4 commit b06262b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

‎lib/active_merchant/billing/gateways/cyber_source.rb

+3-1
Original file line numberDiff line numberDiff line change
@@ -618,7 +618,9 @@ def add_subscription(xml, options, reference = nil)
618618

619619
xml.tag! 'recurringSubscriptionInfo' do
620620
if reference
621-
subscription_id = reference.split(';')[6]
621+
# subscription_id = reference.split(';')[6]
622+
# our subscription/request id has historically been the second item
623+
subscription_id = reference.split(';')[1]
622624
xml.tag! 'subscriptionID', subscription_id
623625
end
624626

0 commit comments

Comments
 (0)