Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:34:40

And ˹mention˺ the Day when He will gather them all and then say to the angels, "Did these ˹people˺ used to worship you?"  

And, mention, on the Day when He will gather them all together, namely, ˹all˺ the idolaters, He will say to the angels, ‘Was it these who used to worship you?’ (read a-hā’ūlā’i iyyākum, pronouncing both hamzas, or by replacing the first with a yā’ or dropping it altogether).
القرآن:٣٤:٤٠

وَيَوْمَ يَحْشُرُهُمْ جَمِيعًا ثُمَّ يَقُولُ لِلْمَلَائِكَةِ أَهَٰؤُلَاءِ إِيَّاكُمْ كَانُوا يَعْبُدُونَ  

{و} اذكر {يوم نحشرهم جميعا} أي المشركين {ثم نقول للملائكة أهؤلاء إياكم} بتحقيق الهمزتين وإبدال الأولى ياء وإسقاطها {كانوا يعبدون}.