Nafi' bin Jubayr bin Mut'im (may Allah have mercy on him) narrates from his father, Sayyiduna Jubayr bin Mut'im (may Allah be pleased with him), that the Prophet (peace and blessings be upon him) said: "The expiation of a gathering is that a person does not get up until he says: 'Glory be to You, O Allah, and with Your praise; there is no deity except You; accept my repentance and forgive me,' saying it three times. If it was a gathering of noise and clamour, it will be an expiation for it, and if it was a gathering of remembrance, it will be a seal upon it."
Hadith Referenceالمعجم الكبير للطبراني / باب الجيم / 1574