apidiesel 0.5 → 0.6

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: 60f1db7f0462707d5b984581b41c98d78d3d4404
4
- data.tar.gz: 9e90978a907d27fed6d8dc56f91141e13a274f5d
3
+ metadata.gz: f14614d104165a4c57043884b7143eb363e6bf54
4
+ data.tar.gz: b662eba5d773821f9a7097fff3bf5be2b7fc955e
5
5
  SHA512:
6
- metadata.gz: 422d9aca10b78ea62722611baa3e8234dcc7b5c05aa2b87ed39dfaae573e358f37e1a0ed160232f3136000cf42b215efad3060ea7c88de4801ec3fa153f9cf8c
7
- data.tar.gz: efb5f850575dd7be9a49bb48319ac1ee973a71b951112dec2a4a65517654b6543796b2418171e98d0fb25b69401cfa0db0191584a9ec634f933632396764a15e
6
+ metadata.gz: 248cde2ab8c6857b7ea9755abf1faf4b5a7006a18274ca443189e03212314b5c6ddd05287ad4043e3c9c49f60aea08b91a1eed79d4bba76b577abda92e2d764f
7
+ data.tar.gz: 1cf3d348ff9141fb282cce019e493714a307706ab04a39c854456081f5abb46b58e0575f7de8929ee98adb831392df6ab8f39c543db23c47faf60eb662a783f7
data/lib/apidiesel/dsl.rb CHANGED
@@ -398,16 +398,21 @@ module Apidiesel
398
398
 
399
399
  hash = apply_filter(args[:prefilter_each], hash)
400
400
 
401
+ next if hash.blank?
402
+
401
403
  builder.response_formatters.each do |filter|
402
404
  result = filter.call(hash, result)
405
+ break if result.blank?
403
406
  end
404
407
 
408
+ next if result.blank?
409
+
405
410
  result = apply_filter(args[:postfilter_each] || args[:filter_each], result)
406
411
 
407
412
  result
408
413
  end
409
414
 
410
- processed_data[ args[:as] ] = array_of_hashes
415
+ processed_data[ args[:as] ] = array_of_hashes.compact!
411
416
 
412
417
  processed_data
413
418
  end
@@ -1,3 +1,3 @@
1
1
  module Apidiesel
2
- VERSION = "0.5"
2
+ VERSION = "0.6"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: apidiesel
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.5'
4
+ version: '0.6'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan-Christian Foeh
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-11-18 00:00:00.000000000 Z
11
+ date: 2015-11-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport