Yahya bin Ya'mar says that I asked Hazrat Aisha (may Allah be pleased with her), "Tell me, would the Prophet (peace be upon him) sleep in a state of janabah?" She replied, "Sometimes he would perform ghusl before sleeping, and sometimes he would sleep before performing ghusl, but he would perform wudu (ablution)." I said, "Praise be to Allah who has made the religion spacious."