that Messenger of Allah ﷺ was asked about an unmarried slave-girl who committed illegal sexual intercourse. They heard him saying, "Flog her, and if she commits illegal sexual intercourse after that, flog her again, and on the third (or the fourth) offense, sell her."
أَخْبَرَهُ أَنَّ زَيْدَ بْنَ خَالِدٍ وَأَبَا هُرَيْرَةَ ؓ أَخْبَرَاهُ أَنَّهُمَا سَمِعَا رَسُولَ اللَّهِ ﷺ يُسْأَلُ عَنِ الأَمَةِ تَزْنِي وَلَمْ تُحْصَنْ قَالَ اجْلِدُوهَا ثُمَّ إِنْ زَنَتْ فَاجْلِدُوهَا ثُمَّ بِيعُوهَا بَعْدَ الثَّالِثَةِ أَوِ الرَّابِعَةِ