President Trump on Wednesday attacked Rep. Beto O'Rourke (D-Texas), calling him a "flake" and saying he "is not in the same league" as his opponent in the Texas Senate race, incumbent Sen. Ted Cruz (R).

"Watched the debate last night & Beto O'Rourke, who wants higher taxes and far more regulations, is not in the same league with Ted Cruz & what the great people of Texas stand for & want," Trump wrote on Twitter. "Ted is strong on Crime, Border & 2nd A, loves our Military, Vets, Low Taxes. Beto is a Flake!"

Trump, who often attacked Cruz while campaigning against him in the Republican presidential primaries in 2016, added in a second tweet that Cruz "has done so much for Texas" and said O'Rourke "would blow it all."

"Ted Cruz has done so much for Texas, including massive cuts in taxes and regulations - which has brought Texas to the best jobs numbers in the history of the state. He watches carefully over your 2nd Amendment. O'Rourke would blow it all! Ted has long had my Strong Endorsement!"

Cruz and O'Rourke squared off Tuesday night in a debate in San Antonio, with the midterm elections about three weeks away.

In the second debate between the two candidates, O'Rourke attacked Cruz from the start, calling him "dishonest" and saying that Cruz is incapable of standing up to Trump.

Cruz also went after the congressman, saying that O'Rourke's record in the House doesn't line up with the values of Texas.

The two debated health care, taxes, immigration and the safeguarding of American elections, among other issues, in what was likely their final debate before next month's midterms.