All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger. We ask Allaah to exalt his mention as well as that of his family and all his companions.
You have to know that what requires having a bath for sexual defilement is sexual intercourse or if the male inserts his sexual organ into that of the female even without ejaculation, or ejaculation while being awake or after a wet dream. So these are the cases when a person is obliged to have a bath for sexual defilement. If after having a bath some discharge comes from the sexual organs, then what is needed is to wash the discharge and make another ablution before performing the prayer.
Allaah knows best.