Sha256: 9ad88efc451d511fa823fe6d6e84e96f965bd005892bdae00195b6fa1ca94272
Contents?: true
Size: 333 Bytes
Versions: 2
Compression:
Stored size: 333 Bytes
Contents
module ElocalApiSupport module Actions module Update def update params.permit! if lookup_object.update_attributes(params[associated_model_name]) render json: lookup_object else render json: { errors: lookup_object.errors }, status: 422 end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
elocal_api_support-0.1.4 | lib/elocal_api_support/actions/update.rb |
elocal_api_support-0.1.3 | lib/elocal_api_support/actions/update.rb |