It is narrated from Sayyiduna Ibn Abbas (may Allah be pleased with them both) that once the Prophet (peace and blessings be upon him) offered the funeral prayer after a person had been buried in the grave.
Hadith Referenceمسند احمد / ومن مسند بني هاشم / 2554