Abu Sa'd (may Allah have mercy on him) narrates: I saw Sayyiduna Wathilah bin al-Asqa' (may Allah be pleased with him) enter the mosque of Damascus, pray, and spit beneath his left foot, then rub it out. When he finished, I said to him: "Do you spit in the mosque, while you are a Companion of the Messenger of Allah (peace and blessings be upon him)?" He said: "This is how I saw the Messenger of Allah (peace and blessings be upon him) do it."
Hadith Referenceالمعجم الكبير للطبراني / باب الواو / 18432