parliament-utils 0.8.7 → 0.9.0

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
  SHA1:
3
- metadata.gz: 287ae1858e83e38907f861a6eee19da93cedb89c
4
- data.tar.gz: 0f320941b79d1ec124babc8469b7fe893edfca9c
3
+ metadata.gz: dc4a06941ea0dea090c59a94a451411e507b0286
4
+ data.tar.gz: 175819e752aa2584803059792de65808d33d3437
5
5
  SHA512:
6
- metadata.gz: 385e63da5667aafd8f14991343fe83f15b65fab68d1dd49fdae8dc3ca2d83cb971b4277b2fc2d381188d6db989e6944a6678fccd5e820311c02d1c7a13be1f13
7
- data.tar.gz: 93e11d863ac58fc57407a6fb5a872474bcad673223920eebd0e9b714322344d812e7d48ae31a8cb317a9ff69ac84ee869aae46db277f9ca067c6e900776f333f
6
+ metadata.gz: f24e4ab9875fa9abe90779da5cbdab723e3097aba1b2bfeabdbd7ad41ecd62e87b566baf5528305d0041af71173f7b647fd96c8f93551941dd252bacac7fcedc
7
+ data.tar.gz: e83122d7a8c75636140dfa6a94ff3aaa7ac909f48ee565f10b6735031fe80225c8d355ec8e1fbe7c409b8e1d74477fb8cd07a052c2436d84b2a7e030effc7234
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.4
1
+ 2.5
@@ -6,8 +6,11 @@ module Parliament
6
6
  module Helpers
7
7
  module ParliamentHelper
8
8
  def self.parliament_request(request_id = nil, request_number = 1)
9
- headers = {'Ocp-Apim-Subscription-Key' => ENV['PARLIAMENT_AUTH_TOKEN'] }
10
- headers['Request-Id'] = "#{request_id}#{request_number}" if request_id
9
+ headers = {}.tap do |headers|
10
+ headers['Ocp-Apim-Subscription-Key'] = ENV['PARLIAMENT_AUTH_TOKEN']
11
+ headers['Api-Version'] = ENV['PARLIAMENT_API_VERSION'] if ENV['PARLIAMENT_API_VERSION']
12
+ headers['Request-Id'] = "#{request_id}#{request_number}" if request_id
13
+ end
11
14
 
12
15
  Parliament::Request::UrlRequest.new(
13
16
  builder: Parliament::Builder::NTripleResponseBuilder,
@@ -1,5 +1,5 @@
1
1
  module Parliament
2
2
  module Utils
3
- VERSION = '0.8.7'.freeze
3
+ VERSION = '0.9.0'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: parliament-utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.7
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rebecca Appleyard
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-06-28 00:00:00.000000000 Z
11
+ date: 2018-07-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: parliament-ruby