americommerce-api 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,7 +21,7 @@ module AmericommerceApi
21
21
 
22
22
  @store_domain = options[:store_domain] + WSDL_POSTFIX
23
23
 
24
- @client = AmericommerceApi::Api.init_client(@ac_header, @store_domain)
24
+ init_client(@ac_header, @store_domain)
25
25
  end
26
26
 
27
27
  def get_orders(options = {})
@@ -45,13 +45,13 @@ module AmericommerceApi
45
45
  def ping
46
46
  begin
47
47
  wsdl = AUTHENTICATE_WSDL % {store_domain: @store_domain}
48
- @client = AmericommerceApi::Api.init_client(@ac_header,wsdl)
48
+ init_client(@ac_header,wsdl)
49
49
  response = request(:authenticate)
50
50
  raise AmericommerceApi::Exceptions::InvalidCredentials unless response == true
51
51
  rescue
52
52
  raise AmericommerceApi::Exceptions::InvalidCredentials
53
53
  ensure
54
- @client = AmericommerceApi::Api.init_client(@ac_header, @store_domain)
54
+ init_client(@ac_header, @store_domain)
55
55
  end
56
56
  end
57
57
 
@@ -62,12 +62,13 @@ module AmericommerceApi
62
62
  return AmericommerceApi::Response.format(response, call_action)
63
63
  end
64
64
 
65
- def self.init_client(ac_header, wsdl)
66
- return Savon.client({
65
+ def init_client(ac_header, wsdl)
66
+ @client = Savon.client({
67
67
  :ssl_verify_mode => :none,
68
68
  :wsdl => wsdl,
69
69
  :soap_header => ac_header,
70
- :namespaces => NAMESPACES
70
+ :namespaces => NAMESPACES,
71
+ :log_level => :warn
71
72
  })
72
73
  end
73
74
 
@@ -1,3 +1,3 @@
1
1
  module Americommerce
2
- VERSION = '0.0.1'
2
+ VERSION = '0.0.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: americommerce-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: