Following his meeting with Russian counterpart Vladimir Putin at Germany’s G20 Summit, Donald Trump sent out a Tweet on Sunday revealing he had discussed forming an “impenetrable” joint cyber security unit with Russia to prevent “election hacking.” But just a few hours later, he appeared to backtrack on his statement.

“Putin & I discussed forming an impenetrable Cyber Security unit so that election hacking, & many other negative things, will be guarded,” Trump wrote. The message came as quite a surprise, given the mounting evidence that Russian-backed hackers attempted to influence last year’s US election, and the alleged ties between Trump’s campaign and Russia.

The tweet drew criticism from both Democrats and some Republicans. "It's not the dumbest idea I have ever heard, but it's pretty close," Senator Lindsey Graham (R - South Carolina) told NBC's Meet the Press program. Republican Senator Marco Rubio also offered his opinion on Twitter.

“If that’s our best election defense, we might as well just mail our ballot boxes to Moscow,” said Representative Adam Schiff, the top Democrat on the House Intelligence Committee.

But those in Trump’s administration jumped to the President’s defense. Secretary of State Rex Tillerson said a dialogue between the two countries is important to “assure the American people that interference in our elections will not occur by Russia or anyone else.”

But around 13 hours after sending out the Tweet, Trump appeared to change his position. "The fact that President Putin and I discussed a cybersecurity unit doesn't mean I think it can happen. It can't," he tweeted, adding that an agreement with Russia for a ceasefire in Syria "can & did" happen.

A leaked NSA report from last month revealed that Russian hackers targeted a voting software firm days before the US election. The Kremlin has repeatedly denied trying to influence the election process, though Putin did say “patriotic hackers” may have tried to meddle with the system.