(A) Except as provided in subparagraph (B), in any case in which— (i) any of the other persons referred to in paragraph (1)(B) is entitled to monthly benefits as a divorced spouse under section 402(b) or (c) of this title for any month, and (ii) such person has been divorced for not less than 2 years, the benefit to which he or she is entitled on the basis of the wages and self-employment income of the individual referred to in paragraph (1) for such month shall be determined without regard to deductions under this subsection as a result of excess earnings of such individual, and the benefits of all other individuals who are entitled for such month to monthly benefits under section 402 of this title on the basis of the wages and self-employment income of such individual referred to in paragraph (1) shall be determined as if no such divorced spouse were entitled to benefits for such month.
(B) Clause (ii) of subparagraph (A) shall not apply with respect to any divorced spouse in any case in which the individual referred to in paragraph (1) became entitled to old-age insurance benefits under section 402(a) of this title before the date of the divorce.