After years of supporting immigration reform, Rep. Jeff Flake (R-Ariz.) has started emphasizing a border-security-first approach as he makes a run for Senate. 

Flake's views on a guest-worker program and other immigration issues were considered his main vulnerability in a GOP Senate primary. But after watching Sen. John McCain (R-Ariz.) successfully tack to the right during his primary fight last year, Flake is now following that playbook.

"In the past I have supported a broad approach to immigration reform — increased border security coupled with a temporary worker program. I no longer do," Flake said in a statement published by the Arizona Republic.

"I've been down that road, and it is a dead end. The political realities in Washington are such that a comprehensive solution is not possible, or even desirable given the current leadership. Border security must be addressed before other reforms are tackled."

The congressman made similar remarks to The Ballot Box when asked about the immigration issue.

"You've got to have some mechanism that deals with those who are here illegally," he said in February. "We dealt with it before with a provision that required them to go home and register. But everything like that is on hold until we have better border security."

Flake could face former Rep. J.D. Hayworth or Rep. Trent Franks in the GOP primary, both of whom would look for space on the lawmaker's right flank.

During McCain's primary against Hayworth last year, the senator parried attacks on his past support for immigration reform by repositioning himself as a border hawk.

The senator even released a widely mocked TV ad wherein he walked along a border fence. In McCain's "danged fence" ad, as it became known, he called for the completion of a border barrier that he had previously criticized.