Sotah 12a: When Pharaoh decreed that all newborn Jewish boys be thrown into the river, Amram said: We are toiling [to have children] in vain. He got up and divorced his wife, and all the Jewish men followed his example and divorced their wives. His daughter said to him, “Father, your decree is harsher than Pharaoh, for Pharaoh’s decree applies only to boys, while yours applies to boys and girls. Pharaoh’s decree takes the children only out of this world, while you take them out of this world and the World to Come. Pharaoh’s decree may or may not be carried out, but you are a tzaddik and your decree will certainly be carried out.”
סוטה יב. עמרם גדול הדור היה, כיון שגזר פרעה הרשע כל הבן הילוד היאורה תשליכוהו, אמר: לשוא אנו עמליןִ עמד וגירש את אשתו, עמדו כולן וגירשו את נשותיהן. אמרה לו בתו: אבא, קשה גזירתך יותר משל פרעה, שפרעה לא גזר אלא על הזכרים, ואתה גזרת על הזכרים ועל הנקיבותִ פרעה לא גזר אלא בעוה״ז, ואתה בעוה״ז ולעוה״בִ פרעה הרשע, ספק מתקיימת גזירתו ספק אינה מתקיימת, אתה צדיק בודאי שגזירתך מתקיימת
Rabbi Elya Boruch Finkel zt”l asked: why did Miriam need to use these arguments? She could have argued simply that we must have children as we are commanded to do, and whatever Hashem does is His business.
Indeed we find two other places where this argument was used: 1) Adam used it to convince Lemech’s wives to return to him, after they had separated for fear that the flood would wipe out their children (Rashi on Bereishis 4:25). 2) Yishaya Hanavi told Chizkiyahu to get married and have children despite his prophecy that his children would be wicked (Berachos 10a).
R’ Elya Boruch answered that there is a difference between a Heavenly decree and a human decree. If one is afraid to have children because that will result in the children suffering from a misfortune that Hashem will cause, then he must know that the same Hashem who is bringing the misfortune also commanded you to have children. But if one is afraid the children will suffer from a human being who wishes to harm them, that is a good reason not to do the mitzvah.
This is similar to a question posed by Rabbi Yosef Aryeh Lorincz to Rabbi Chaim Kanievsky: The Nefesh Hachaim 4:11 famously says that if for one moment there would be no one in the world learning Torah, the world would be destroyed. What if a person knew that he was the only one in the world learning, and suddenly a life-threatening situation arose? Should he stop learning to save the life? If he does, then the whole world would be in danger.
According to the above, R’ Elya Boruch said, the answer is that yes, he must save the life. He must do as he was commanded in the Torah, and should not worry about the world being destroyed, since he is not the one doing the destruction – Hashem is, and Hashem commanded him to save the life.