The verse (Bereishit 38:20) states: “And Yehudah sent the kid by the hand of his Adullamite friend to take the pledge from the woman’s hand, but he did not find her.”
On this Reb Mendel of Kotzk commented:[1]
“A person must have a friend with whom he feels comfortable revealing everything about himself—including his sins. We learn this from Yehudah, who was not ashamed to reveal his debauchery to his Adullamite friend.”
[1] Reb Mendelei M’Kotzk, (Ehrich) Pg. 65