President Trump on Tuesday thanked outgoing UN Ambassador Nikki Haley for her service, calling her “someone who is very special to me” during a joint appearance at the White House after she announced her resignation.

“She’s done a fantastic job, and we have done a fantastic job together. We have solved a lot of problems, and we’re in the process of solving a lot of problems. At the beginning, North Korea was a massive problem, and now we’re moving along. It’s moving along really nicely,” the commander-in-chief said.

Trump at one point said Haley would be welcome back to the administration any time — a remark that caused her to break into good-natured laughter.

Haley then listed what she said were the administration’s accomplishments on the world stage on her watch.

“Look at the two years, look at what has happened in two years with the United States on foreign policy. Now the United States is respected. Countries may not like what we do, but they respect what we do,” Haley said.

“They know that if we say we’re going to do something, we follow it through. And the president proved that. Whether it was with the chemical weapons in Syria, whether it’s with NATO, saying that other countries have to pay their share, and whether it’s the trade deals, which have been amazing. They get that the president means business, and they follow through with that.”

She also praised Trump’s family, singling out the first lady and Jared Kushner, the president’s son-in-law, whom she called “such a hidden genius that no one understands.”

Haley resigned earlier in the day, the latest shake-up in the turbulent administration just weeks before the midterm elections.

Haley was appointed to the post in November 2016 and last month coordinated Trump’s second trip to the UN, including his first time chairing the Security Council.

Before she was named by Trump to the UN job, Haley was governor of South Carolina, the first woman to hold the post.

National security adviser John Bolton and Secretary of State Mike Pompeo were both reportedly caught off guard by the abrupt resignation.

But Haley had discussed her resignation with the president last week when she visited the White House, Axios reported.

While her reasons were not entirely clear, Haley had said she had no 2020 presidential ambitions and will campaign for Trump.

Last month Haley wrote an op-ed in the Washington Post discussing her policy disagreements but also her pride in working for Trump.

It came in response to an anonymous essay in the New York Times by a senior administration official that alleged there was a secret “resistance” effort from the right in Trump’s administration and that there were internal discussions of invoking the 25th Amendment to remove him from office.

“I proudly serve in this administration, and I enthusiastically support most of its decisions and the direction it is taking the country,” Haley wrote. “But I don’t agree with the president on everything.”

As governor, she developed a national reputation as a racial conciliator who led the charge to bring down the Confederate flag at the Statehouse and guided South Carolina through one of its darkest moments, the massacre at a black church.

With AP