lib/active_merchant/billing/gateways/realex.rb in activemerchant-1.26.0 vs lib/active_merchant/billing/gateways/realex.rb in activemerchant-1.27.0
- old
+ new
@@ -17,12 +17,12 @@
#
# the Realex team decided to make the orderid unique per request,
# so if validation fails you can not correct and resend using the
# same order id
class RealexGateway < Gateway
- URL = 'https://epage.payandshop.com/epage-remote.cgi'
-
+ self.live_url = self.test_url = 'https://epage.payandshop.com/epage-remote.cgi'
+
CARD_MAPPING = {
'master' => 'MC',
'visa' => 'VISA',
'american_express' => 'AMEX',
'diners_club' => 'DINERS',
@@ -79,14 +79,14 @@
end
def void(authorization, options = {})
request = build_void_request(authorization, options)
commit(request)
- end
-
- private
- def commit(request)
- response = parse(ssl_post(URL, request))
+ end
+
+ private
+ def commit(request)
+ response = parse(ssl_post(self.live_url, request))
Response.new(response[:result] == "00", message_from(response), response,
:test => response[:message] =~ /\[ test system \]/,
:authorization => authorization_from(response),
:cvv_result => response[:cvnresult],