moysklad 0.3.1 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6fad3cc93541b8fa239ed1a6e3e7a900d2206117589163067f85289abb0261b3
4
- data.tar.gz: bc7c87f9765092342522ffba77d6178c00f670e4e8f5363f77f7055c17a80f9d
3
+ metadata.gz: abdc083d3dbc4b8020ce96a71f348d4da052c9a9a85ff66acb1b5c16e3ba1a89
4
+ data.tar.gz: e925e1cd59dda2dffa9cb16b855989ed35901239ca1e56d08ae9c6d9d4db8bb8
5
5
  SHA512:
6
- metadata.gz: 2149b17c96a6dcf5a8006f16173739caeb4745f0055921d548d46b9c084a4fc083d6f644e6ff6407cdd7f0563be0fdff43f84e37b3b7a7c77568a16127b09ad6
7
- data.tar.gz: 5f3ad953ea673c0e69d1fef4405ab5711e8cd603c88a93fa57ac49cda7f2fd8353723da25abcc6b54076416dbc5b5858ed39d1738cb223cde9414a200505126d
6
+ metadata.gz: 10c0597144a06f4c3b243c3f8309a2ae1d241dfbe575280a9dd1d9144c4040a29441229ba392c6ddf51bbb52916f414dbdb14822c5ac22270fed77061f05a966
7
+ data.tar.gz: 6d374cfec6e3985bad837f7d82a26d50cc9436c3a5f6f5b54c3fe940fa75337f9743e176d70d0e5db1281cffa9a7a0d3e6a3fefbe1e373853a2c5b776b80fbc0
@@ -9,7 +9,11 @@ class Moysklad::Client
9
9
 
10
10
  def initialize login: nil, password: nil
11
11
  @client = Faraday.new URL do |conn|
12
- conn.request(:authorization, :basic, login, password)
12
+ if Faraday::VERSION.split('.').first.to_i < 2
13
+ conn.request(:basic_auth, login, password)
14
+ else
15
+ conn.request(:authorization, :basic, login, password)
16
+ end
13
17
  end
14
18
  end
15
19
 
@@ -1,3 +1,3 @@
1
1
  module Moysklad
2
- VERSION = "0.3.1"
2
+ VERSION = "0.3.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: moysklad
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Danil Pismenny