It is narrated from Hazrat Aisha (may Allah be pleased with her) that the Prophet (peace and blessings be upon him) said: Three types of people are exempt from accountability; no command is applied to them: first, the sleeping person until he wakes up; second, the child until he reaches puberty; and third, the insane person until he regains his senses.