booking_locations 0.6.0 → 0.6.1

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: 32a99d8cdce3cdfedc42e876dc225d3db5de2637
4
- data.tar.gz: 2a3a1f730d693206b0ed4440f7c03af15ddf1e51
3
+ metadata.gz: c789914f44c7cd1bd28c7c29eaffbb3bf50b2811
4
+ data.tar.gz: c4604c3cce0fff0062021787441454d2a6781063
5
5
  SHA512:
6
- metadata.gz: 283e4901d9174e1f49ff5b063bb9ee441c5a67c60d44c217130de227f26a7bfe01b46e5d25cddb9fe7e1ea0a5e036da17c6df699d89599c085a5097768dae69e
7
- data.tar.gz: 528103ba0d79e97af6785a535532283abc42be87664353b0fa2a22af0c9e0e425feecd34cdf3955e157062d75f5be075a584f5f97dd32f3cbd7978707b83c770
6
+ metadata.gz: 802847e45f23997efc0edd91a9377bd9555a9a80f2ed34b055c485439a9f5a18bfbf801ac43764ebe87669c737b4d61262c70c83530776555c155e2611cd96d5
7
+ data.tar.gz: f19ef07e6bed5e629531ae04241f30a5048d35aa9ed3a6b4f061685fb812255c7bd51665d513d586313fd5de153e0cce0304e3ad544e54139091e95e4bf52ada
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 0.6.1
2
+
3
+ * Replace our own null cache with Rails' `NullStore`
4
+
1
5
  ## 0.6.0
2
6
 
3
7
  * Adds configurable caching for location responses
@@ -2,9 +2,9 @@ require 'booking_locations/version'
2
2
  require 'booking_locations/api'
3
3
  require 'booking_locations/slot'
4
4
  require 'booking_locations/location'
5
- require 'booking_locations/null_cache'
6
5
 
7
6
  require 'active_support/core_ext/module/attribute_accessors'
7
+ require 'active_support/cache/null_store'
8
8
 
9
9
  module BookingLocations
10
10
  DEFAULT_TTL = 2 * 60 * 60 # 2 hours
@@ -17,7 +17,7 @@ module BookingLocations
17
17
  end
18
18
 
19
19
  def self.cache
20
- @@cache ||= BookingLocations::NullCache.new
20
+ @@cache ||= ActiveSupport::Cache::NullStore.new
21
21
  end
22
22
 
23
23
  def self.find(id, expires = DEFAULT_TTL)
@@ -1,3 +1,3 @@
1
1
  module BookingLocations
2
- VERSION = '0.6.0'.freeze
2
+ VERSION = '0.6.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: booking_locations
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Lovell
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-08-04 00:00:00.000000000 Z
11
+ date: 2016-08-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -135,7 +135,6 @@ files:
135
135
  - lib/booking_locations.rb
136
136
  - lib/booking_locations/api.rb
137
137
  - lib/booking_locations/location.rb
138
- - lib/booking_locations/null_cache.rb
139
138
  - lib/booking_locations/slot.rb
140
139
  - lib/booking_locations/stub_api.json
141
140
  - lib/booking_locations/stub_api.rb
@@ -1,7 +0,0 @@
1
- module BookingLocations
2
- class NullCache
3
- def fetch(*)
4
- yield
5
- end
6
- end
7
- end