module Payments
  class PurchaseProfilePolicy < ApplicationPolicy
    def index?
      allowed?
    end

    def show?
      allowed?
    end

    def cancel?
      allowed?
    end

    def do_not_renew?
      allowed?
    end

    def sync_ticket_access?
      allowed?
    end

    def allowed?
      user.permitted? BeefCake::Permission.for(:purchase_profiles)
    end
  end
end
