lib/fawry.rb in fawry-1.2.1 vs lib/fawry.rb in fawry-1.3.0
- old
+ new
@@ -1,11 +1,12 @@
# frozen_string_literal: true
require 'fawry/version'
+require 'fawry/utils'
require 'fawry/connection'
+require 'fawry/config'
require 'fawry/errors'
-require 'fawry/utils'
require 'fawry/fawry_request'
require 'fawry/fawry_response'
require 'fawry/fawry_callback'
require 'fawry/requests/charge_request'
require 'fawry/requests/refund_request'
@@ -19,9 +20,15 @@
require 'fawry/contracts/create_card_token_request_contract'
require 'fawry/contracts/list_tokens_request_contract'
require 'fawry/contracts/delete_token_request_contract'
module Fawry
+ configure do |config|
+ config.sandbox = false
+ config.fawry_secure_key = nil
+ config.fawry_merchant_code = nil
+ end
+
class << self
# Sends a charge request to Fawry API
# performs param validation and builds
# the request signature
#