Abdullah bin Umar reported,

The Messenger of Allah ﷺ saw some spittle on the wall facing the qiblah. He scraped it off, then turned to the people and said, "When one of you is praying, he should not spit in front of him, for Allah تبارك وتعالى is in front of him when he prays."

Azami 2618

Sahih

عن عبد الله بن عمر

أن رسول الله ﷺ رأى بصاقا في جدار القبلة، فحكه ثم أقبل على الناس فقال: إذا كان أحدكم يصلي فلا يبصق قبل وجهه، فإن الله تبارك وتعالى قبل وجهه إذا صلى.

الأعظمي 2618صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Prayer
Chapter
What is prohibited and disliked in prayer
Section
Prohibition of spitting toward the qibla during prayer
Numbering
Jami al-Kamil 2618 (2nd edition)
Azami 2618