Joseph was a righteous man. This means he obeyed the law (see Luke 1:6). He reconsidered marrying Mary because it appeared she had committed adultery. He could have cleared his name by publicly accusing Mary. This would have led to her trial and possible execution (Deuteronomy 22:23–27; compare Numbers 5:11–31). Or he could pay a fine and end the engagement (see also Mishnah Sotah 1:1–5). Joseph chose to be kind and decided to end the engagement quietly.