Sha256: 5a7e4638c347c2e64a9b9664b4f8cd318af8a451c2d32bb305e66cd45b5e271f
Contents?: true
Size: 529 Bytes
Versions: 6
Compression:
Stored size: 529 Bytes
Contents
module Spree module Api class AddressesController < Spree::Api::BaseController def show @address = Address.find(params[:id]) authorize! :read, @address respond_with(@address) end def update @address = Address.find(params[:id]) authorize! :read, @address if @address.update_attributes(params[:address]) respond_with(@address, :default_template => :show) else invalid_resource!(@address) end end end end end
Version data entries
6 entries across 6 versions & 1 rubygems