(a) Except as otherwise expressly provided by a law of the State, the State, its officers, and its units may not raise the defense of sovereign immunity in a contract action, in a court of the State, based on a written contract that an official or employee executed for the State or 1 of its units while the official or employee was acting within the scope of the authority of the official or employee.
(b) In an action under this subtitle, the State and its officers and units shall have the immunity from liability described under § 5-522(d) of the Courts and Judicial Proceedings Article.