; (B) enforce compliance with such subsection, regulation, or statement; (C) obtain damages, restitution, or other compensation on behalf of residents of the State; or (D) obtain such other legal and equitable relief as the court may consider to be appropriate. (2) Notice Before filing an action under this subsection against a person, partnership, or corporation over which the Commission has jurisdiction under section 5(a)(2) of the Federal Trade Commission Act ( 15 U.S.C. 45(a)(2) ) (except to the extent such person, partnership, or corporation is a law enforcement contractor or subcontractor) or an air carrier or foreign air carrier, the attorney general, official, or agency of the State involved shall provide to the Commission a written notice of that action and a copy of the complaint for that action. If the attorney general, official, or agency determines that it is not feasible to provide the notice described in this paragraph before the filing of the action, the attorney general, official, or agency shall provide written notice of the action and a copy of the complaint to the Commission immediately upon the filing of the action. (3) Authority of the Commission (A) In general On receiving notice under paragraph (2) of an action under this subsection, the Commission shall have the right— (i) to intervene in the action; (ii) upon so intervening, to be heard on all matters arising therein