rabl 0.11.6 → 0.11.7

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: 852d10093718c0d837774cbb5503b64cd7474305
4
- data.tar.gz: 39d7b1d6c51be9b181431d127b8e19456bcda4a3
3
+ metadata.gz: 5364500887b2b3da7ed0bb4d68dd5ebd0948fc27
4
+ data.tar.gz: 3854ce5f9c6dc02937bebfde51d8dd3dc96d4134
5
5
  SHA512:
6
- metadata.gz: 46aaee2c97be7740ec16880d9fa59fec495cc136e11854a9685137e593c06c8325e3fd4e9a07e929fe0d2c3b22b1aa8ab6a8319c90048f8882474779316d380f
7
- data.tar.gz: a574e74f6489c8bbb40ce57c1d6ad8738d1d634f9fe9bc793eabf5a0dea6421329ad94a0f1ff22927ba6b31c69bb9499c087ba7eef12457627717fe7a100277f
6
+ metadata.gz: af825d57438c23e1e19427eb665098a077c9c7183578d597fad01a70fe75d7503519377ce5fab8f9d2b5558b6b4536df7e416ae9d9f7409ca82cb0508df8987d
7
+ data.tar.gz: 343dd2bc3856274826aaaaa81bfb93ffff77ee88dbf6777de0a95e4e61ade920167d64130e408a44c01951ffbf71772b3998c06d3a39788c1ea70a98ec83065f
@@ -1,5 +1,10 @@
1
1
  # CHANGELOG
2
2
 
3
+ ## 0.11.7 (December 6th, 2015)
4
+
5
+ * Use empty hash as default cache options (@infertux)
6
+ * Update ERB::Util link in README (@mortonfox)
7
+
3
8
  ## 0.11.6 (January 26th)
4
9
 
5
10
  * Fix resolve_condition and simplify call_condition_proc (@vmeyet)
data/README.md CHANGED
@@ -170,7 +170,7 @@ If `cache_all_output` is set to `true`, every template including each individual
170
170
  Additionally, anything within child, glue and partial will also be cached separately.
171
171
  To cache just a single template, see the section titled 'Caching' below.
172
172
 
173
- If `escape_all_output` is set to `true` and ActiveSupport is available, attribute output will be escaped using [ERB::Util.html_escape](http://corelib.rubyonrails.org/classes/ERB/Util.html).
173
+ If `escape_all_output` is set to `true` and ActiveSupport is available, attribute output will be escaped using [ERB::Util.html_escape](http://api.rubyonrails.org/classes/ERB/Util.html).
174
174
 
175
175
  If `view_paths` is set to a path, this view path will be checked for every rabl template within your application.
176
176
  Add to this path especially when including Rabl in an engine and using view paths within a another Rails app.
@@ -628,7 +628,6 @@ Tutorials can always be helpful when first getting started:
628
628
  * http://blog.joshsoftware.com/2011/12/23/designing-rails-api-using-rabl-and-devise/
629
629
  * http://engineering.gomiso.com/2011/06/27/building-a-platform-api-on-rails/
630
630
  * http://blog.lawrencenorton.com/better-json-requests-with-rabl
631
- * http://www.rodrigoalvesvieira.com/developing-json-api-rails-rabl/
632
631
  * http://tech.favoritemedium.com/2011/06/using-rabl-in-rails-json-web-api.html
633
632
  * http://seesparkbox.com/foundry/better_rails_apis_with_rabl
634
633
  * http://blog.dcxn.com/2011/06/22/rails-json-templates-through-rabl
@@ -213,7 +213,7 @@ module Rabl
213
213
  # cache # uses the current item within a collection
214
214
  # cache 'user', expires_in: 1.hour
215
215
  # options is passed through to the cache store
216
- def cache(key = nil, options = nil)
216
+ def cache(key = nil, options = {})
217
217
  key ||= root_object # if called but missing, use object
218
218
  @_cache_key = key
219
219
  @_cache_options = options
@@ -138,12 +138,12 @@ module Rabl
138
138
 
139
139
  # Fetches a key from the cache and stores rabl template result otherwise
140
140
  # fetch_from_cache('some_key') { ...rabl template result... }
141
- def fetch_result_from_cache(cache_key, cache_options = nil, &block)
141
+ def fetch_result_from_cache(cache_key, cache_options = {}, &block)
142
142
  expanded_cache_key = ActiveSupport::Cache.expand_cache_key(cache_key, :rabl)
143
143
  Rabl.configuration.cache_engine.fetch(expanded_cache_key, cache_options, &block)
144
144
  end
145
145
 
146
- def write_result_to_cache(cache_key, cache_options = nil, &block)
146
+ def write_result_to_cache(cache_key, cache_options = {}, &block)
147
147
  expanded_cache_key = ActiveSupport::Cache.expand_cache_key(cache_key, :rabl)
148
148
  result = yield
149
149
  Rabl.configuration.cache_engine.write(expanded_cache_key, result, cache_options)
@@ -1,3 +1,3 @@
1
1
  module Rabl
2
- VERSION = "0.11.6"
2
+ VERSION = "0.11.7"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rabl
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.6
4
+ version: 0.11.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Esquenazi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-26 00:00:00.000000000 Z
11
+ date: 2015-12-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -468,7 +468,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
468
468
  version: '0'
469
469
  requirements: []
470
470
  rubyforge_project: rabl
471
- rubygems_version: 2.0.6
471
+ rubygems_version: 2.4.8
472
472
  signing_key:
473
473
  specification_version: 4
474
474
  summary: General ruby templating with json, bson, xml and msgpack support