Captain Cold returned to The Flash in the May 16 episode, bringing some much needed levity and breaking and entering skills to the Team on "Infantino Street." Barry's last ditch effort to save Iris is this close to coming to fruition. Tracy and HR successfully create the Speed Bazooka, a weapon to trap Savitar in the Speed Force, so the only thing they need is an energy source to power it. And that's where Captain Cold comes in: Barry needs Snart to help him steal an alien power source from ARGUS. In other words, Captain Cold is Barry's last hope to save Iris on The Flash.
After Lyla refuses to simply give the alien power source to Barry (she doesn't trust him after Flashpoint, RIP Baby Sara), Barry needs to find someone capable of breaking into an ARGUS facility to help him. Lyla is a professional, and the ARGUS facility is rigged with security measures and devices that prevent Barry from using his powers. So, Barry breaks his time travel rule one last time (JK, he's totally going to do it again) to go back to the 1800s and track Captain Cold down in Siberia. With his cold gun and his extensive background as a thief, Snart is the perfect partner to help Barry.
Snart successfully helps Barry bypass ARGUS security and tame King Shark — who was being used as a guard dog — long enough to grab the alien energy source from the ARGUS vault. But, when the alarm sounds and Snart is locked in with King Shark, Barry has to make a choice: grab the alien power source and run, or stay and save Captain Cold from certain death. Even though he wants to leave, Barry does the right thing. He saves Snart, and his act of kindness convinces Lyla to give him the power source. Granted, in the end, Barry still isn't successful in stopping Savitar. But, at least we got to see Captain Cold and The Flash team up once more, right?