lhc 7.0.0 → 7.0.1

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: bbf8c19f3a1808c9ee8ae502cc835ec24a6b75ac
4
- data.tar.gz: 3d12a0c83e3498c49cd8b498b26c4bf6fab05789
3
+ metadata.gz: b9e147beaadc8fe3e310a38644dccd8b35f4054c
4
+ data.tar.gz: d84dacb1f0997890b2c82d8b74d09b374c14ff28
5
5
  SHA512:
6
- metadata.gz: 75b261d1b95a04a77ca8eb5913b5285d3e6e3780562ff9a3f37e985dca9f4c52dd1dc97bec71e5eec97e15406d645ea908c7802ac9e2b9834611ae81d5510f65
7
- data.tar.gz: 6e95f8c8754241b62f91d37e46f02eb823aef6b14a6fdd8ef1b5d2c3aba7da4c92ae2312018be9733567c07e60a5a088c3bdb60b5a552214458c87016af50093
6
+ metadata.gz: b41ec31a4305805cc15f3847dc32a1bcd2bc57aceba386947fe0b94c974237f9634bed91cf64edeec2ae486e1283b9883c6e49828b66af781ee0b91b50ca8937
7
+ data.tar.gz: 145f320dee707973d2ee7f675f51a5c7592f818b02cb942dcbfa1ea648fcd67d92a77bf9b64d0c96c52e0e7f2dd5022cbea566524fa321535437fa185ddde42a
@@ -61,10 +61,10 @@ class LHC::Endpoint
61
61
 
62
62
  # eliminate false positives in form:
63
63
  # http://host/feedbacks matches {+service}/{entry_id}/feedbacks (service: http:/, entry_id: host)
64
- first.match(%{https?:/$}).nil? &&
64
+ first&.match(%{https?:/$}).nil? &&
65
65
  # eliminates false positives in form:
66
66
  # http://host/entries/123.json matches {+service}/entries/{id} (service: http://host, id: 123.json)
67
- (url_format.blank? || !last.ends_with?(url_format))
67
+ (url_format.blank? || !last&.ends_with?(url_format))
68
68
  end
69
69
 
70
70
  # Extracts the values from url and
@@ -1,3 +1,3 @@
1
1
  module LHC
2
- VERSION ||= '7.0.0'
2
+ VERSION ||= '7.0.1'
3
3
  end
@@ -11,7 +11,9 @@ describe LHC::Endpoint do
11
11
  'http://local.ch/addresses/{id}' => 'http://local.ch/addresses/123',
12
12
  '{+datastore}/customers/{id}/addresses' => 'http://local.ch:80/server/rest/v1/customers/123/addresses',
13
13
  '{+datastore}/entries/{id}.json' => 'http://local.ch/entries/123.json',
14
- '{+datastore}/places/{place_id}/feedbacks' => 'http://local.ch/places/1/feedbacks?limit=10&offset=0'
14
+ '{+datastore}/places/{place_id}/feedbacks' => 'http://local.ch/places/1/feedbacks?limit=10&offset=0',
15
+ 'http://local.ch/places/1/feedbacks' => 'http://local.ch/places/1/feedbacks?lang=en',
16
+ 'http://local.ch/places/1/feedbacks.json' => 'http://local.ch/places/1/feedbacks.json?lang=en'
15
17
  }.each do |template, url|
16
18
  it "#{url} matches #{template}" do
17
19
  expect(LHC::Endpoint.match?(url, template)).to be
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lhc
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.0.0
4
+ version: 7.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - https://github.com/local-ch/lhc/contributors
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-01-16 00:00:00.000000000 Z
11
+ date: 2018-01-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus