MECHANICSBURG, PA – AUGUST 01: Republican Presidential nominee Donald Trump addresses supporters at a campaign rally on August 1, 2016 in Mechanicsburg, Pennsylvania. Trump spoke to some 5,000 people at the Cumberland Valley High School in eastern Pennsylvania on the last day of his campaign swing through “Rust Belt” states. (Photo by John Moore/Getty Images)

House Speaker Paul Ryan (R-Wis.) is taking a lot of heat this week for repeatedly criticizing Republican presidential nominee Donald Trump but continuing to endorse him.

Trump repaid his loyalty on Monday by tweeting a positive message to Ryan’s Republican challenger, Paul Nehlen, ahead of the Aug. 9 primary.

Nehlen has gone after Ryan using a similar playbook to Trump’s: a relentless focus on unauthorized immigration and trade, accusing Ryan of favoring open borders and letting American jobs go overseas.

He has also been a Trump booster and defender, including over the candidate and his allies’ attacks on the mother and father of Army Capt. Humayun S.M. Khan, a fallen soldier who was Muslim. Trump has gone after his parents, Khizr and Ghazala Khan, after they appeared at the Democratic National Convention last week to say he had “sacrificed nothing,” and that their son wouldn’t even be in the U.S. if Trump had his way and kept Muslims from immigrating here.

Ryan issued a statement Sunday reiterating his opposition to a religious test for entering the U.S. and saying the Khans should be honored for their sacrifice.

Nehlen posted multiple blog posts and tweets defending Trump. He wrote that Ryan was misrepresenting Trump’s immigration policy, which started as a call to “temporarily” ban Muslims from entering the U.S. before an “expansion,” in Trump’s words, to block people from countries “compromised by terrorism.” Nehlen also defended the idea of a religious test.

Nehlen criticized the Khan family personally as well:

Ryan campaign spokesman Zack Roday did not address Nehlen or Trump directly in his comment, saying, “Rather than engage in a back-and-forth, the Speaker is going to remain focused entirely on ensuring we deliver strong Republican majorities this fall.”