He did his job, and in doing his job he embarrassed the president. Trump fires people that embarrass him.