Directly after forty days (of nifaas) I fasted to make up what I owed from Ramadaan, and whilst I was fasting I found that there was a yellowish discharge with no blood, but this was the usual time for my period. My question is: is my fast valid or do I have to repeat it and make it up again? Please note that I am praying and I did not stop praying because most of the time I have the signs of tahaarah (being pure) and I did not see anything that would make me stop praying.
The majority of scholars are of the view that the maximum length of nifaas is forty days; if the bleeding lasts any longer than that, then it is istihaadah (irregular bleeding) unless it happens at the usual time of menses, in which case it is menses.
See the answer to question no. 10488.
Based on this, if you saw blood after forty days and it coincided with the usual time of your period, then it is menses. As for yellowish discharge, it does not mean anything, because Umm ‘Atiyyah (may Allaah be pleased with her) said: “We did not regard yellowish and brownish discharge after tuhr (becoming pure) as being of any significance.” Narrated by Abu Dawood (307) and classed as saheeh by al-Albaani in Saheeh Abu Dawood.
You did right to continue praying and make up the fast you owed. May Allaah increase you in knowledge and guidance.
And Allaah knows best.