President Donald Trump slammed the use of anonymous sources today—hours after promoting a story based almost entirely on them.

In a pair of tweets this morning, Trump claimed that anonymous sources are often "fiction":

"Anonymous Sources are really starting to BURN the media." @FoxNews The fact is that many anonymous sources don't even exist. They are fiction made up by the Fake News reporters. Look at the lie that Fake CNN is now in. They got caught red handed! Enemy of the People! — Donald J. Trump (@realDonaldTrump) August 29, 2018

When you see "anonymous source," stop reading the story, it is fiction! — Donald J. Trump (@realDonaldTrump) August 29, 2018

Trump was responding to a CNN story published last month. Citing unidentified sources, CNN claimed that Trump's former lawyer, Michael Cohen, was prepared to testify before Special Counsel Robert Mueller that the then-candidate had advance knowledge of the infamous June 2016 meeting between a Russian lawyer and several Trump associates. Trump has said he only learned about the meeting roughly a year after the fact.

Over the weekend, Cohen lawyer/spokesperson Lanny Davis told The Washington Post that he was one of CNN's sources. Later, Davis admitted to NBC that he couldn't confirm if Cohen would indeed testify before Mueller.

So the CNN story certainly deserves the criticism it's been getting. But the president may want to refrain from declaring that reports citing anonymous sources are invariably "fiction." Just last night, after all, he tweeted this:

Report just out: "China hacked Hillary Clinton's private Email Server." Are they sure it wasn't Russia (just kidding!)? What are the odds that the FBI and DOJ are right on top of this? Actually, a very big story. Much classified information! — Donald J. Trump (@realDonaldTrump) August 29, 2018

Hillary Clinton's Emails, many of which are Classified Information, got hacked by China. Next move better be by the FBI & DOJ or, after all of their other missteps (Comey, McCabe, Strzok, Page, Ohr, FISA, Dirty Dossier etc.), their credibility will be forever gone! — Donald J. Trump (@realDonaldTrump) August 29, 2018

The story in question came from The Daily Caller News Foundation, which based much of its reporting on—you guessed it—two anonymous sources: an intelligence officer and a government staff official.

Trump's criticism looks even more hypocritical when you remember he's been an anonymous source himself many times over the years. He was also notorious for pretending to be his own publicist, using aliases like "John Barron" or "John Miller" to brag about himself to reporters. But that's not necessarily inconsistent, if you assume the brags were fictions.