When the Messenger of Allah ﷺ arrived in Mecca, he refused to enter the House while the idols were still inside it. He ordered that they be removed, and they were taken out. Among what was brought out was an image of Ibrahim and Ismail, peace be upon them, holding divining arrows in their hands.The Messenger of Allah ﷺ said, "May Allah destroy them. By Allah, they knew full well that these two never cast lots with these arrows."Then he entered the House and pronounced the takbir in its corners, and he came out without praying inside it.
حدثنا عبد الصمد حدثني أبي أخبرنا أيوب عن عكرمة
أن رسول الله ﷺ لما قدم مكة أبى أن يدخل البيت وفيه الآلهة فأمر بها فأخرجت فأخرج صورة إبراهيم وإسماعيل عليهما السلام في أيديهما الأزلام فقال رسول الله ﷺ قاتلهم الله أما والله لقد علموا ما اقتسما بها قط قال ثم دخل البيت فكبر في نواحي البيت وخرج ولم يصل في البيت
Its isnad is sahih. Bukhari narrated it from Ishaq bin Mansur from Abdul-Samad, as mentioned in the History of Ibn Kathir, 4:302, where he said, "Bukhari alone narrated it," meaning Muslim did not narrate it. See also 2508 and 2834.