Sunan an-Nasa'i, Hadith 1488 ⓘ
It was narrated from An-Nu'man bin Bashir that : The Prophet said: "If there is an eclipse of the sun or the moon, pray like the last obligatory prayer you did before that."
أَخْبَرَنَا مُحَمَّدُ بْنُ الْمُثَنَّى، عَنْ مُعَاذِ بْنِ هِشَامٍ، قَالَ حَدَّثَنِي أَبِي، عَنْ قَتَادَةَ، عَنْ أَبِي قِلاَبَةَ، عَنِ النُّعْمَانِ بْنِ بَشِيرٍ، أَنَّ النَّبِيَّ صلى الله عليه وسلم قَالَ " إِذَا خَسَفَتِ الشَّمْسُ وَالْقَمَرُ فَصَلُّوا كَأَحْدَثِ صَلاَةٍ صَلَّيْتُمُوهَا " .
also referenced under: Book 16, Hadith 30 (In-Book) & Volume 2, Book 16, Hadith 1489 (DarusSalam)