tobirama was short sighted imo
danzo's ideals mirrored his the most and he prob would have completely wiped out the uchiha population including sasuke if he thought they posed a threat to the village.
At this point I think the Uchiha demise was inevitable
As Tobirama explained it, the Uchiha feel love far greater than normal people, and when their emotions get tainted it their eyes respond to the trauma and they receive greater power to enact vengeance. Tobirama was fearful of the Uchiha but he didn't do anything drastic, all he did was propose a democratic vote for the Hokage seat. Madara as paranoid as he was immediately saw that as an open declaration of war, the hate filled his heart so quickly he started envisioning Tsukuyomi as the solution to the world's problems.
Tobirama then tried to slowly shift Uchiha's loyalty towards the village instead of the clan, as he did with all other clans. He did understand that the Uchiha power can be used for good and evil, but there was nothing he could do to ensure the future generations maintain their steadiness. I don't think their fate could've been changed, they're a cursed clan through and through going back to their forefather. Danzo was a paranoid asshole, I'd argue fear of Madara can push one to do terrible things lol