algoliasearch 1.1.9 → 1.1.10

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b8882d4f271cee303c8d2e1f5a07abc0d19036e5
4
- data.tar.gz: a06efbbc79ed53a94820edb418df4aafbea45caa
3
+ metadata.gz: 44798747404ff35fdb5615eb23c0c2de53cba36f
4
+ data.tar.gz: 3748e5a659bf37cf6b5643ac44954e6637247ce3
5
5
  SHA512:
6
- metadata.gz: 512669deeac5deb73c644ca50c0ba67f1728f2238835cf487b3f99fe8a25ce019b85a6aefa12b7ab034ca60e729d391f5471290a21e87b1103559feb45fd4a3a
7
- data.tar.gz: fcfb7cd72481579b62d51937b19bcae24f7e01399a457d0d1a636f211adb49781584f2b0d0abe1912b2c243c6e71a0a5767d76acf10a99f1b6d5df93c7ff2111
6
+ metadata.gz: 56b88360c2f076c427c9c30353c92a066f539fbb60df652aaf2180db29a4598b9143ee7f1891ff04ff146c81ddf9bff863ab00eb5676f2f292c7f13136c1c410
7
+ data.tar.gz: cdb63ccc75378a65b9b39660fc1fcd48abebe4efec632af336cbaeab49e77e608fb1110022ef5e2c1c9e4c7707164bc94d6209c49ac1add17e997aff4d986c89
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "algoliasearch"
8
- s.version = "1.1.9"
8
+ s.version = "1.1.10"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Algolia"]
@@ -17,7 +17,6 @@ module Algolia
17
17
  @ssl = data[:ssl].nil? ? true : data[:ssl]
18
18
  @application_id = data[:application_id]
19
19
  @api_key = data[:api_key]
20
- @gzip = data[:gzip].nil? ? true : data[:gzip]
21
20
  @hosts = (data[:hosts] || 1.upto(3).map { |i| "#{@application_id}-#{i}.algolia.io" }).shuffle
22
21
  @debug = data[:debug]
23
22
  end
@@ -46,11 +45,7 @@ module Algolia
46
45
  if session.response_code >= 400 || session.response_code < 200
47
46
  raise AlgoliaProtocolError.new(session.response_code, "Cannot #{method} to #{session.url}: #{session.body_str} (#{session.response_code})")
48
47
  end
49
- if @gzip
50
- gz = Zlib::GzipReader.new(StringIO.new(session.body_str))
51
- return JSON.parse(gz.read)
52
- end
53
- return JSON.parse(session.body_str)
48
+ return JSON.parse(session.body_str)
54
49
  rescue AlgoliaProtocolError => e
55
50
  raise if e.code != Protocol::ERROR_TIMEOUT and e.code != Protocol::ERROR_UNAVAILABLE
56
51
  exceptions << e
@@ -91,8 +86,8 @@ module Algolia
91
86
  s.headers[Protocol::HEADER_APP_ID] = application_id
92
87
  s.headers["Content-Type"] = "application/json; charset=utf-8"
93
88
  s.headers["User-Agent"] = "Algolia for Ruby #{::Algolia::VERSION}"
94
- s.headers["Accept-Encoding"] = "gzip,deflate" if @gzip
95
89
  s.verbose = true if @debug
90
+ s.encoding = ''
96
91
  end
97
92
  hinfo
98
93
  end
@@ -1,3 +1,3 @@
1
1
  module Algolia
2
- VERSION = "1.1.9"
2
+ VERSION = "1.1.10"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: algoliasearch
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.9
4
+ version: 1.1.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Algolia