The Messenger of Allah ﷺ said, "Jibreel came to me and said, 'I came to you last night, and nothing prevented me from entering except that there were figures at the door, and inside the house there was a curtain with figures on it, and there was a dog in the house. So order that the head of the figure inside the house be cut off so that it resembles the form of a tree, and order that the curtain be cut and made into two cushions strewn on the ground to be sat upon, and order that the dog be put out.'"The Messenger of Allah ﷺ did so. The dog belonged to Hasan or Husayn and had been under a stand of theirs, so he ordered it to be removed, and it was put out.
حدثنا أبو صالح محبوب بن موسى حدثنا أبو إسحق الفزاري عن يونس بن أبي إسحق عن مجاهد قال
قال رسول الله ﷺ أتاني جبريل عليه السلام فقال لي أتيتك البارحة فلم يمنعني أن أكون دخلت إلا أنه كان على الباب تماثيل وكان في البيت قرام ستر فيه تماثيل وكان في البيت كلب فمر برأس التمثال الذي في البيت يقطع فيصير كهيئة الشجرة ومر بالستر فليقطع فليجعل منه وسادتين منبوذتين توطآن ومر بالكلب فليخرج ففعل رسول الله ﷺ وإذا الكلب لحسن أو حسين كان تحت نضد لهم فأمر به فأخرج
[Sahih] Reported by Tirmidhi, Adab, chapter on what has been said that the angels do not enter a house in which there is a picture or a dog, no. 2806, from the hadith of Yunus, and Nasai, no. 5367, from the hadith of Mujahid on the same subject. Tirmidhi said, hasan sahih, and Ibn Hibban graded it sahih, no. 1487.