But the Lord was with Joseph, and showed him mercy and loving-kindness and gave him favor in the sight of the warden of the prison.