Sunan Ibn Majah, Book 5, Hadith 157 (Ibn Majah 959)

It was narrated that Ibn ‘Abbas said:

“The Messenger of Allah (ﷺ) forbade performing prayer behind one who is engaged in conversation or one who is sleeping.”