Abu Zubair reported that he heard 'Abd al-Rahman b. Aiman (the freed slave of 'Azza) say that he asked Ibn 'Umar (Allah be pleased with them) and Abu Zubair heard
What is your opinion about the person who divorced his wife in the state of menses? Thereupon he said: Ibn Umar (Allah be pleased with them) divorced his wife during the lifetime of Allah's Messenger (ﷺ) while she was in the state of menses. Upon this Allah's Messenger (ﷺ) told him to take her back and so he took her back and he (further) said: When she is pure, then either divorce her or retain her. Ibn 'Umar (Allah be pleased with them) said that Allah's Apostle (ﷺ) then recited this verse:" O Apostle, when you divorce women, divorce them at the commencement of their prescribed period" (Ixv 1).