Question: "Illicit sex is wrong and jesus christ was in realtion with mary magdalene,"
Jesus' relation with magdalene is not the only lie you believe in. That is a fabrication created by an anti christian author. He himself writes that it is a fiction. There are absolutely no evidence for Jesus having any unwanted relations with magdalene. Instead Jesus cast out 7 demons out of magdalene and gave her a new life.
Mark 16:9 Now when He rose early on the first day of the week, He appeared first to Mary Magdalene, out of whom He had cast seven demons.