If you think about it, the sympathy and bond to the animals was long there before she got turned into flutterbat and I imagine the experience (and little residue of the transformative magic) deepened that bond further. By turning Fluttershy into a bat-version of herself, the other Mane 6 first started thinking about how these animals work and how to solve the problem without simply driving them off. So the action against the bats opened the path to the real solution.



I tried to work this twist into the picture by using the song lyrics and changing them accordingly into the version Flutterbat might've had in her head.