Sha256: be414d35bd3471939d852e81929289c844efc1ee454f9dea441ae12e63cf50c3
Contents?: true
Size: 563 Bytes
Versions: 15
Compression:
Stored size: 563 Bytes
Contents
module Spree module Api module V2 module Storefront class AccountConfirmationsController < ::Spree::Api::V2::BaseController def show user = Spree.user_class.confirm_by_token(params[:id]) if user.errors.empty? render json: { data: { state: user.respond_to?(:state) ? user.state : '' } }, status: :ok else render json: { error: user.errors.full_messages.to_sentence }, status: :unprocessable_entity end end end end end end end
Version data entries
15 entries across 15 versions & 1 rubygems