Sahih Muslim , Book 9, Hadith 3480 (USC-MSA)

Ibn 'Umar (Allah be pleased with them) reported that he divorced his wife while she was in her menses. 'Umar (Allah be pleased with him) asked Allah's Apostle about that, and he said: Command him to take her back until she is pure and then she enters the second menses and then becomes pure. Then either divorce her (finally) or retain her.

وَحَدَّثَنِي أَحْمَدُ بْنُ عُثْمَانَ بْنِ حَكِيمٍ الأَوْدِيُّ، حَدَّثَنَا خَالِدُ بْنُ مَخْلَدٍ، حَدَّثَنِي سُلَيْمَانُ، - وَهُوَ ابْنُ بِلاَلٍ - حَدَّثَنِي عَبْدُ اللَّهِ بْنُ دِينَارٍ، عَنِ ابْنِ عُمَرَ، أَنَّهُ طَلَّقَ امْرَأَتَهُ وَهْىَ حَائِضٌ فَسَأَلَ عُمَرُ عَنْ ذَلِكَ رَسُولَ اللَّهِ صلى الله عليه وسلم فَقَالَ ‏ "‏ مُرْهُ فَلْيُرَاجِعْهَا حَتَّى تَطْهُرَ ثُمَّ تَحِيضَ حَيْضَةً أُخْرَى ثُمَّ تَطْهُرَ ثُمَّ يُطَلِّقَ بَعْدُ أَوْ يُمْسِكَ ‏" ‏ ‏.‏

sunnah.com