jsonapi-serializers 0.6.4 → 0.6.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -0
- data/lib/jsonapi-serializers/serializer.rb +1 -1
- data/lib/jsonapi-serializers/version.rb +1 -1
- data/spec/serializer_spec.rb +0 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3f3ea0a6b146f6d472d29baeab24e9250af5a445
|
4
|
+
data.tar.gz: 12b7df3f2f154caeebc75bcebb238437343ae908
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 38c6c932bf6dc7d56876bdfdd4f03994bbbba29e9d548152d2d55c4366ef1a89d707dd23b5f2f160516ee183cfdc15b7408f48ece62835da5a28adea86760a6e
|
7
|
+
data.tar.gz: 14fc35998aab4db62f6b92f77b053120bb6ba69a911fdfbed63fd616bb17b2a51bb67017c1322f9121af4f3572cbcd18ca08704d7857ecc754a1bae3f7597f05
|
data/README.md
CHANGED
@@ -652,6 +652,7 @@ end
|
|
652
652
|
|
653
653
|
## Release notes
|
654
654
|
|
655
|
+
* v0.6.5: Exclude attributes when empty.
|
655
656
|
* v0.6.4: Fix regression of including links when empty.
|
656
657
|
* v0.6.3: Fix support for underscore-formatted attribute names.
|
657
658
|
* v0.6.2: Internal style updates and performance fixes.
|
@@ -331,7 +331,7 @@ module JSONAPI
|
|
331
331
|
links = serializer.links
|
332
332
|
relationships = serializer.relationships
|
333
333
|
meta = serializer.meta
|
334
|
-
data['attributes'] = attributes if !attributes.
|
334
|
+
data['attributes'] = attributes if !attributes.empty?
|
335
335
|
data['links'] = links if !links.empty?
|
336
336
|
data['relationships'] = relationships if !relationships.empty?
|
337
337
|
data['meta'] = meta if !meta.nil?
|
data/spec/serializer_spec.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jsonapi-serializers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Fotinakis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -123,7 +123,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
123
123
|
version: '0'
|
124
124
|
requirements: []
|
125
125
|
rubyforge_project:
|
126
|
-
rubygems_version: 2.
|
126
|
+
rubygems_version: 2.4.5
|
127
127
|
signing_key:
|
128
128
|
specification_version: 4
|
129
129
|
summary: Pure Ruby readonly serializers for the JSON:API spec.
|
@@ -132,3 +132,4 @@ test_files:
|
|
132
132
|
- spec/spec_helper.rb
|
133
133
|
- spec/support/factory.rb
|
134
134
|
- spec/support/serializers.rb
|
135
|
+
has_rdoc:
|