Skip to content

Commit

Permalink
SecureNet: Allow production transactions
Browse files Browse the repository at this point in the history
The TEST parameter was always being sent as true!  Now we only pass that
parameter at the right time.

Closes activemerchant#805.
  • Loading branch information
duff authored and ntalbott committed Aug 15, 2013
1 parent a3fe276 commit 0facc1f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

* MerchantWarrior: Fix handling of amounts [duff]
* MerchantWarrior: Send the CVV to the gateway [duff]
* SecureNet: Allow production transactions [duff]

== Version 1.36.0 (August 2, 2013)

Expand Down
5 changes: 2 additions & 3 deletions lib/active_merchant/billing/gateways/secure_net.rb
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,8 @@ def commit(request)
data = ssl_post(url, xml, "Content-Type" => "text/xml")
response = parse(data)

test_mode = test?
Response.new(success?(response), message_from(response), response,
:test => test_mode,
:test => test?,
:authorization => build_authorization(response),
:avs_result => { :code => response[:avs_result_code] },
:cvv_result => response[:card_code_response_code]
Expand Down Expand Up @@ -208,7 +207,7 @@ def add_required_params(xml, action, options)

def add_more_required_params(xml, options)
xml.tag! 'RETAIL_LANENUM', '0'
xml.tag! 'TEST', 'TRUE'
xml.tag! 'TEST', 'TRUE' if test?
xml.tag! 'TOTAL_INSTALLMENTCOUNT', 0
xml.tag! 'TRANSACTION_SERVICE', 0
end
Expand Down

0 comments on commit 0facc1f

Please sign in to comment.