app/controllers/spree/api/stores_controller.rb in solidus_api-2.10.5 vs app/controllers/spree/api/stores_controller.rb in solidus_api-2.11.0

- old
+ new

@@ -4,12 +4,12 @@ module Api class StoresController < Spree::Api::BaseController before_action :get_store, except: [:index, :create] def index - authorize! :read, Store - @stores = Spree::Store.accessible_by(current_ability, :read).all + authorize! :index, Store + @stores = Spree::Store.accessible_by(current_ability).all respond_with(@stores) end def create authorize! :create, Store @@ -30,10 +30,10 @@ invalid_resource!(@store) end end def show - authorize! :read, @store + authorize! :show, @store respond_with(@store) end def destroy authorize! :destroy, @store