restful-jsonapi 1.0.6 → 1.0.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
- SHA1:
3
- metadata.gz: e8c629eaa79b98d7fb7a0e267f6b3b8a1d250794
4
- data.tar.gz: 7133eca2fcf09c8dab46ab30a892b206b5524b74
2
+ SHA256:
3
+ metadata.gz: 289dd0ec75b00fbdf07719c19d9fde24b6c8cb26517e32f52ae254481885de3e
4
+ data.tar.gz: 61f7aa986da1c75a0ba9004d6948dc6b85fe66cf4493571a3dedcb5be4e51e57
5
5
  SHA512:
6
- metadata.gz: 82e7171dbf181d4ef43eb32ab8949c82bf67586a985e40ce6139f04b8059002ad7320c96b27b838d60de34202d1be2f203257570acff5547bdc0842d422d79cc
7
- data.tar.gz: 44d98ca953818240d2caa480d984f0ae5c86497afe6536cf351b668b99b4c916f26c7eb25a3ed7748a23b3447dc071a5fb6d3cf69dfd05e134be188b53c8aa69
6
+ metadata.gz: 79a3e4829b05295ea90659badfb4f6711460cfc8e48cb9f731a59d2dfce8b27e71a0a11cf472d3397c0fce6ccba12743fd2be27b1530b66e1a53e0e2a47e94d0
7
+ data.tar.gz: 7fd46955294e723f3eb9e75eb9bc7298e5f72de3fbc187056e403c33fdf765deafa5a0234bfef08abd557d5b14dfbfb492376c871b0b628e8952ab5d72519bbe
@@ -3,17 +3,13 @@ module Restful
3
3
  class Railtie < Rails::Railtie
4
4
  initializer "restful-jsonapi.action_controller" do
5
5
  ActiveSupport.on_load(:action_controller) do
6
- puts "Extending #{self} with Restful::Jsonapi::RestifyParam"
7
6
  include Restful::Jsonapi::RestifyParam
8
-
9
- puts "Extending #{self} with Restful::Jsonapi::SerializableErrors"
10
7
  include Restful::Jsonapi::SerializableErrors
11
8
  end
12
9
  end
13
10
 
14
11
  initializer "restful-jsonapi.active_model_serializer" do
15
12
  ActiveModel::Serializer.class_eval do
16
- puts "Extending #{self} with Restful::Jsonapi::ActiveModelSerializer"
17
13
  include Restful::Jsonapi::ActiveModelSerializer
18
14
  end
19
15
  end if defined? ActiveModel::Serializer
@@ -13,8 +13,9 @@ module Restful
13
13
  if value == params
14
14
  value = params.clone[:data] # leave params alone
15
15
  end
16
- value.delete(:type)
17
16
  new_params = ActionController::Parameters.new
17
+ return new_params if value.nil?
18
+ value.delete(:type)
18
19
  # relationships
19
20
  if value.has_key? :relationships
20
21
  value.delete(:relationships).each do |relationship_name, relationship_data|
@@ -1,5 +1,5 @@
1
1
  module Restful
2
2
  module Jsonapi
3
- VERSION = "1.0.6"
3
+ VERSION = "1.0.7"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: restful-jsonapi
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Zach Wentz
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2018-01-22 00:00:00.000000000 Z
14
+ date: 2019-05-06 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: rails
@@ -103,8 +103,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
103
103
  - !ruby/object:Gem::Version
104
104
  version: '0'
105
105
  requirements: []
106
- rubyforge_project:
107
- rubygems_version: 2.5.1
106
+ rubygems_version: 3.0.3
108
107
  signing_key:
109
108
  specification_version: 4
110
109
  summary: Nice type and params for temporary JSONAPI support.