Sha256: 4ffbf75cd6e8fa3520ea0748febf7083742ccde5e7cb1013ca31bfda912be6bf
Contents?: true
Size: 630 Bytes
Versions: 1
Compression:
Stored size: 630 Bytes
Contents
module MerbMerchant module Billing module PaypalExpressCommon def self.included(base) base.cattr_accessor :test_redirect_url base.cattr_accessor :live_redirect_url base.live_redirect_url = 'https://www.paypal.com/cgibin/webscr?cmd=_express-checkout&token=' end def redirect_url test? ? test_redirect_url : live_redirect_url end def redirect_url_for(token, options = {}) options = {:review => true}.update(options) options[:review] ? "#{redirect_url}#{token}" : "#{redirect_url}#{token}&useraction=commit" end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
merb_merchant-1.4.1 | lib/merb_merchant/billing/gateways/paypal_express_common.rb |