Wa laqad hammat bihee wa hamma bihaa law laaa ar ra-aa burhaana rabbih;; kazaalika linasrifa 'anhu sooo'a walfa hshaaa'; innahoo min 'ibaadi nal mukhlaseen
And she certainly determined [to seduce] him, and he would have inclined to her had he not seen the proof [i.e., sign] of his Lord. And thus [it was] that We should avert from him evil and immorality. Indeed, he was of Our chosen servants.
1 Mufti Taqi Usmani
She certainly desired him, and he might have desired her, had he not seen the proof from his Lord. Thus We did, to turn evil and lewdness away from him. Surely, he was one of Our chosen servants.