While Daenerys was busy conquering Vaes Dothrak and adding the Dothraki to her armies, Tyrion was stuck running diplomacy between the masters and the freed slaves back at Meereen. Just as the masters lay siege to the city, Daenerys and her dragons take back Meereen in the Season 6 Game of Thrones episode "Battle of the Bastards."
Sure, the main focus of this episode is on Jon Snow and Ramsay Bolton's epic matchup, but plenty was happening across the Narrow Sea in Essos, too. Yara and Theon Greyjoy made what has to be the fastest voyage in Game of Thrones history to make a pact with Daenerys, offering her their ships to take over Westeros in exchange for being reinstated as rulers of The Iron Islands.
But before all that went down, Dany was busy trying to defend Meereen from flaming cannonballs flying out of the masters' ships docked in Slaver's Bay and destroying the city. She had a scorched earth plan to take over, but Tyrion cautions her against leaning into her Mad Queen tendencies. So she concedes to negotiating the masters' surrender, but, foolishly, they decide to run their mouths about some slaughtering her dragons and kicking her out of the city nonsense. That, needless to say, is not how this is going to go down. Daenerys summons her dragon, mounts him like the dragon rider than she is, frees her other two babies, and fire-breathes the crap out of some ships.
Sidebar: while all this is gloriously going down, Daario leads the Dothraki on the ground in slaughtering a hoard of Sons of the Harpy. As if dragons destroying the masters' ships isn't enough, back at the pyramid, Tyrion, Greyworm, and Missandre kill two of the three masters leading the armies attacking Slaver's Bay. They send the last one to tell his people what has happened. Basically, the masters are never staging an uprising again for as long as dragons roam the earth and Daenerys Stormborn lives. Meereen will remain a free city, though perhaps it will continue to be a city in turmoil, since Dany plans on bouncing westward as soon as possible, leaving them in the shambles of forced emancipation without any infrastructure to uphold it.