Here is a blog post by IslamicSalvation, which can be found here:
باب الرجل يصلي وحده ثم يعيد في الجماعة أو يصلي بقوم و قد كان صلى قبل
ذلك
Chapter on the man who prays alone and then repeats it in Jama’ah or leads a people in prayer having prayed (alone) before
محمد بن إسماعيل، عن الفضل بن شاذان، وعلي بن إبراهيم، عن أبيه جميعا، عن ابن أبي عمير، عن حفص بن البختري، عن أبي عبدالله (عليه السلام) في الرجل يصلي الصلاة وحده ثم يجد جماعة قال: يصلي معهم ويجعلها الفريضة (حسن كالصحيح)
1. Muhammad bin Ismail from Fadhl bin Shadhan AND Ali bin Ibrahim from his father (Ibrahim bin Hashim) all together from Ibn Abi Umayr from Hafs bin al-Bukhtariy from Abi Abdillah (a.s) - about the man who prays (a prayer) alone (and completes it), and then finds a Jama’ah (congregation - praying the same prayer he had prayed), He (a.s) said : he prays with them (again), and makes this one (prayed in congregation) the Faridha (obligatory prayer) (and the other one will remain a Nafila). (Hasan like Sahih)
محمد بن يحيى، عن أحمد بن محمد، عن ابن أبي عمير، عن هشام بن سالم، عن سليمان بن خالد قال: سألت أبا عبدالله (عليه السلام) عن رجل دخل المسجد وافتتح الصلاة فبينا هو قائم يصلي إذا أذن المؤذن وأقام الصلاة، قال: فليصل ركعتين ثم ليستأنف الصلاة مع الامام ولتكن الركعتان تطوعا (صحيح)
2. Muhammad bin Yahya from Ahmad bin Muhammad from Ibn Abi Umayr from Hisham bin Salim from Sulayman bin Khalid who said : I asked Aba Abdillah (a.s) about a man who enters the Masjid, and begins praying (the obligatory prayer - alone), so while he is standing praying, the Muadhin makes the Adhan and the Iqamah (as a prelude to the start of the congregational prayer – what should the man do?) , He (a.s) said : he should just complete the two Rakaat (from his prayer), and join the imam (to pray what he was intending to pray – but now in congregation), and the two Rakaat shall become those of the Nafila. (Sahih)
جماعة، عن أحمد بن محمد، عن الحسين بن سعيد، عن يعقوب بن يقطين قال:
قلت لابي الحسن (عليه السلام): جعلت فداك تحضر صلاة الظهر فلا نقدر أن ننزل في الوقت حتى ينزلوا وننزل معهم فنصلي ثم يقومون فيسرعون فنقوم فنصلي العصر ونريهم كأنا نركع ثم ينزلون للعصر فيقدمونا فنصلي بهم؟ فقال: صل بهم، لا صلى الله عليهم (صحيح)
3. A large number of my teachers from Ahmad bin Muhammad from Husayn bin Said from Yaqub bin Yaqtin who said : I said to Abil Hasan (a.s) : may I be ransomed for you, the time for (the prayer of) Dhuhr arrives, so we do not have the opportunity to pray it in its earliest time (i.e pray for ourselves - due to their presence), until they (the A’mma) begin praying it, so we join them, and pray with them, then they stand and depart, so we stand and pray the Asr, and make it look as though we are praying of the Nafila (after Dhuhr), then they come for the Asr and proceed for it, so we pray (again) behind them (is this right?), so He (a.s) said : pray with them, may Allah (s.w.t) not bless them. (Sahih)
محمد بن يحيى، عن أحمد بن محمد، عن محمد بن إسماعيل قال: كتبت إلى أبي الحسن (عليه السلام) أني أحضر المساجد مع جيرتي وغيرهم فيأمروني بالصلاة بهم وقد صليت قبل أن آتيهم وربما صلى خلفي من يقتدي بصلاتي والمستضعف والجاهل وأكره أن أتقدم وقد صليت بحال من يصلي بصلاتي ممن سميت لك، فمزني في ذلك بأمرك أنتهي إليه وأعمل به إن شاء الله فكتب (عليه السلام) صل بهم (صحيح)
4. Muhammad bin Yahya from Ahmad bin Muhammad from Muhammad bin Ismail (al-Baziu) who said : I wrote to Abil Hasan (a.s) (as follows) – I attend the (prayers in the) Masajid, with the neighbours (of my community), and also the others apart from them, so they request me to lead them in prayer, and I (normally) pray (by myself) before I come to them, and it is possible (at any given occasion - while leading them) that those praying behind me are – (people) who follow me in my prayer (i.e from the Kha’ssa), and from the oppressed (i.e straightened – without a choice), and from the ignorant (i.e from the Amm’a), and I dislike to lead them while having already prayed (because I am in doubt about) the condition (i.e the validity, of the prayer) of those who pray behind me with my prayer (depending on it, since I am their imam - but I have already prayed before) from the (categories of people) I have mentioned (above), so order me in regards to it with your command, that I may turn to it (in reference), and act according to it, so He (a.s) wrote to me : pray with them (and lead them). (Sahih)
علي بن أبراهيم، عن أبيه، عن ابن أبي عمير، عن حماد، عن الحلبي، عن أبي عبدالله (عليه السلام) قال: من صلى معهم في الصف الاول كان كمن صلى خلف رسول الله (صلى الله عليه وآله) (حسن)
5. Ali bin Ibrahim from his father (Ibrahim bin Hashim) from Ibn Abi Umayr from Hammad (bin Uthman) from al-Halabiy from Abi Abdillah (a.s) who said : whoever prays with them in the first row, is like the one who prays behind the messenger of Allah (s.a.w.w). (Hasan)
محمد بن يحيى، عن أحمد بن محمد، عن عثمان بن عيسى، عن سماعة قال: سألته
عن رجل كان يصلي فخرج الامام وقد صلى الرجل ركعة من صلاة فريضة فقال: إن كان إماما عدلا فليصل اخرى وينصرف ويجعلهما تطوعا وليدخل مع الامام في صلاته كما هو وإن لم يكن إمام عدل فليبن على صلاته كما هو ويصلي ركعة اخرى معه يجلس قدر ما يقول: أشهد أن لا إله إلا الله وحده لا شريك له وأشهد أن محمدا عبده ورسوله (صلى الله عليه وآله)، ثم ليتم صلاته معه على ما استطاع فإن التقية واسعة وليس شئ من التقية إلا وصاحبها مأجور عليها إن شاء الله (موثق)
6. Muhammad bin Yahya from Ahmad bin Muhammad from Uthman bin Isa from Sam’ah (bin Mihran) who said : I asked Him (a.s) about a man who was praying (an obligatory prayer - alone), so (while he was doing that) an imam emerges (wishing to lead a congregational prayer), and he (the man) has (already) prayed a single Rakaat (from his individual prayer), so He (a.s) said : if it is a just imam (who emerges), then he should pray the other Rakaat (to make it two) and (complete this prayer) and make it a Nafila, and then enter with the imam in his (the imam’s) prayer (making it a new beginning). And if it is not a just imam (who emerges), then he should continue with his own prayer (that he had started and was in), and pray the other Rakaat (of his individual prayer - while making it look as though he has started afresh) with the imam, sitting in it for the duration in which he can say : ‘There is no god but Allah, and Muhammad is his messenger’ (as his Tashahud - after this imam’s first Rakaat and what is his second), then complete his own prayer behind the imam as best as he can, for Taqiyyah is wide (all-encompasing), and there is not a thing (done) in Taqiyyah but its performer is rewarded for it, if Allah wills. (Muwathaq)