Class: Spree::Api::V2::Storefront::Account::CreditCardsController

Inherits:
ResourceController show all
Defined in:
app/controllers/spree/api/v2/storefront/account/credit_cards_controller.rb

Instance Method Summary collapse

Methods inherited from ResourceController

#index, #show

Methods included from Caching

#collection_cache_key, #collection_cache_opts

Methods included from CollectionOptionsHelpers

#collection_links, #collection_meta, #collection_permitted_params

Methods inherited from BaseController

#content_type

Instance Method Details

#destroyObject



9
10
11
12
13
# File 'app/controllers/spree/api/v2/storefront/account/credit_cards_controller.rb', line 9

def destroy
  spree_authorize! :destroy, resource, resource

  destroy_service.call(card: resource)
end