(وَعَنْهُ مِنْ طَرِيقٍ ثَانٍ) أَنَّ رَسُولَ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَآلِهِ وَسَلَّمَ قَالَ: ((إِذَا قَالَ الْإِمَامُ سَمِعَ اللَّهُ لِمَنْ حَمِدَهُ فَقُولُوا: اللَّهُمَّ رَبَّنَا لَكَ الْحَمْدُ فَإِنَّ مَنْ وَافَقَ قَوْلَهُ قَوْلَ الْمَلَائِكَةِ غُفِرَ لَهُ مَا تَقَدَّمَ مِنْ ذَنْبِهِ))
(Second chain) The Messenger of Allah, peace and blessings be upon him, said: When the imam says "Sami' Allahu liman hamidah," you should say "Allahumma Rabbana lakal hamd." So whoever's words coincide with the words of the angels, his past sins will be forgiven.