The Messenger of Allah ﷺ said: When one of you places in front of him so me. thing such as the back of a saddle, he should pray without caring who passes on the other side of it.
قَالَ رَسُولُ اللَّهِ ﷺ إِذَا وَضَعَ أَحَدُكُمْ بَيْنَ يَدَيْهِ مِثْلَ مُؤْخِرَةِ الرَّحْلِ فَلْيُصَلِّ وَلاَ يُبَالِ مَنْ مَرَّ وَرَاءَ ذَلِكَ