infield 0.1.2 → 0.1.3

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
  SHA256:
3
- metadata.gz: a148efd7dfef4844beb8cdcd51d3f216b978cff6276d9024a41b0569adee659c
4
- data.tar.gz: 516b173ccc44026ba41b46f638661c735b69122c4a192048bf2df2cffe769078
3
+ metadata.gz: e62979b43ae9bf3fff7bea388d4fb59fd9c9bb91d08f41f8b986c7bf5e4bae39
4
+ data.tar.gz: 724d1b82c5a9c629f12bf9730923cf05388a8d374b5613218f92ccf9e13842b0
5
5
  SHA512:
6
- metadata.gz: 4b38da3d8f7a3027aa6ec0841a09f42c9f43c479279bbf6a95d7aa74b005782e8deb02cc266430a841d8038acb5c6e92c9972169c067000058373c1f63e55ec8
7
- data.tar.gz: cadc173453c974e65441bffff71eb776f10387d1fd6d4c017ba6846c68b39c69f710fc5d36e3ade98f38cd2af2573c63993dffb2895b425ffd83c65f3c3465b5
6
+ metadata.gz: 84f01fd9f71ee65e7f01833fa972aa5dc5bfcac50869d34110db64fee9a933fd76f41be2aca6b5916759f1997efeb0c87dc76fdf3046bd2601201f2db7a97752
7
+ data.tar.gz: 12a31dcdb3e226c102a0d0aa2ce6be3c61de84024817b82e300217f1197b95b5f6778e731418eb391696d7a341a9f7b7f5fe24379b7fa22c4fe06ead8ae99e5e
@@ -40,10 +40,12 @@ module Infield
40
40
  end
41
41
 
42
42
  def upload_message(task)
43
- http = Net::HTTP.new(infield_api_uri.host, infield_api_uri.port)
44
- http.post('/api/raw_deprecation_warnings',
45
- default_api_params.merge(message: task.message).to_json,
46
- { 'Content-Type' => 'application/json', 'Authorization' => "bearer #{Infield.api_key}" })
43
+ uri = infield_api_uri
44
+ Net::HTTP.start(uri.host, uri.port, use_ssl: (uri.scheme == 'https')) do |http|
45
+ http.post('/api/raw_deprecation_warnings',
46
+ default_api_params.merge(message: task.message).to_json,
47
+ { 'Content-Type' => 'application/json', 'Authorization' => "bearer #{Infield.api_key}" })
48
+ end
47
49
  end
48
50
 
49
51
  def deliver
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Infield
4
- VERSION = '0.1.2'
4
+ VERSION = '0.1.3'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: infield
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Infield