(A) A claim secured by a lien on property of the estate shall be allowed or disallowed under section
502 of this title the same as if the holder of such claim had recourse against the debtor on account of such claim, whether or not such holder has such recourse, unless
(i) the class of which such claim is a part elects, by at least two-thirds in amount and more than half in number of allowed claims of such class, application of paragraph (2) of this subsection; or
(ii) such holder does not have such recourse and such property is sold under section
363 of this title or is to be sold under the plan.
(B) A class of claims may not elect application of paragraph (2) of this subsection if
(i) the interest on account of such claims of the holders of such claims in such property is of inconsequential value; or
(ii) the holder of a claim of such class has recourse against the debtor on account of such claim and such property is sold under section
363 of this title or is to be sold under the plan.