One of the wives of ʿUmar (bin Al-Khattab) used to offer the Fajr and the ʿIsha' prayer in congregation in the Mosque. She was asked why she had come out for the prayer as she knew that ʿUmar disliked it, and he has great ghaira (self-respect). She replied, "What prevents him from stopping me from this act?" The other replied, "The statement of Messenger of Allah ﷺ : 'Do not stop Allah's women-slaves from going to Allah's Mosques' prevents him." (Using translation from Bukhārī 900)
كَانَتِ امْرَأَةٌ لِعُمَرَ ؓ تَشْهَدُ صَلَاةَ الصُّبْحِ وَالْعِشَاءِ فِي الْجَمَاعَةِ فِي الْمَسْجِدِ فَقِيلَ لَهَا لِمَ تَخْرُجِينَ وَقَدْ تَعْلَمِينَ أَنَّ عُمَرَ يَكْرَهُ ذَلِكَ وَيَغَارُ؟ قَالَتْ فَمَا يَمْنَعُهُ أَنْ يَنْهَانِي؟ قَالَ يَمْنَعُهُ قَوْلُ رَسُولِ اللهِ ﷺ قَالَ لَا تَمْنَعُوا إِمَاءَ اللهِ مَسَاجِدَ اللهِ