Bulugh al-Maram 1035
وَعَنْ جَابِرٍ - رضي الله عنه - قَالَ: كُنَّا نَعْزِلُ عَلَى عَهْدِ رَسُولِ اللَّهِ - صلى الله عليه وسلم - وَالْقُرْآنُ يَنْزِلُ, وَلَوْ كَانَ شَيْئًا يُنْهَى عَنْهُ لَنَهَانَا عَنْهُ الْقُرْآنُ. مُتَّفَقٌ عَلَيْهِ. ⦗٣١٣⦘ وَلِمُسْلِمٍ: فَبَلَغَ ذَلِكَ نَبِيَّ اللَّهِ - صلى الله عليه وسلم - فَلَمْ يَنْهَنَا.
From Jabir, may Allah be pleased with him, who said: We used to practise ʿazl in the time of the Messenger of Allah ﷺ while the Quran was being revealed, and if it had been something to be forbidden, the Quran would have forbidden it to us. Agreed upon. Muslim has: That reached the Prophet of Allah ﷺ, and he did not forbid us.