Throw the baby out with the bathwater

What does “Throw the baby out with the bathwater” mean?

It means to be doing something that ruins, damages or prevents more elements than are necessary. i.e. where you only need to make a change to one thing (bathwater), you are going beyond this and making damaging changes to a more valuable thing (the baby).