Except as provided in section 1123 (a)(4) of this title, a class of claims or interests is impaired under a plan unless, with respect to each claim or interest of such class, the plan—
(1) leaves unaltered the legal, equitable, and contractual rights to which such claim or interest entitles the holder of such claim or interest; or
(2) notwithstanding any contractual provision or applicable law that entitles the holder of such claim or interest to demand or receive accelerated payment of such claim or interest after the occurrence of a default—
(A) cures any such default that occurred before or after the commencement of the case under this title, other than a default of a kind specified in section 365 (b)(2) of this title or of a kind that section 365 (b)(2) expressly does not require to be cured;
(B) reinstates the maturity of such claim or interest as such maturity existed before such default;
(C) compensates the holder of such claim or interest for any damages incurred as a result of any reasonable reliance by such holder on such contractual provision or such applicable law;
(D) if such claim or such interest arises from any failure to perform a nonmonetary obligation, other than a default arising from failure to operate a nonresidential real property lease subject to section 365 (b)(1)(A), compensates the holder of such claim or such interest (other than the debtor or an insider) for any actual pecuniary loss incurred by such holder as a result of such failure; and
(E) does not otherwise alter the legal, equitable, or contractual rights to which such claim or interest entitles the holder of such claim or interest.