lib/jsonapi/routing_ext.rb in jsonapi-resources-0.3.0.pre2 vs lib/jsonapi/routing_ext.rb in jsonapi-resources-0.3.0
- old
+ new
@@ -128,10 +128,10 @@
if methods.include?(:create)
match "links/#{formatted_association_name}", controller: res._type.to_s,
action: 'create_association', association: link_type.to_s, via: [:post]
end
- if methods.include?(:update) && res._association(link_type).acts_as_set
+ if methods.include?(:update)
match "links/#{formatted_association_name}", controller: res._type.to_s,
action: 'update_association', association: link_type.to_s, via: [:put, :patch]
end
if methods.include?(:destroy)