According to Immanuel Kant the truth should be told no matter the outcome this is the idea behind what he called moral universalism the categorical imperative moral relativism or the veil of ignorance

This idea is behind what he called the categorical imperative. Kant believed that we have a moral duty to always tell the truth, regardless of the consequences or outcome. The categorical imperative is a principle of universal morality that applies to all rational beings, and requires us to act in a way that is consistent with universal laws. Kant argued that telling the truth is always the right thing to do, no matter what the circumstances may be.