Hadithcore
Mishkat al-Masabih, 448

Ubayy b. Ka'b said that “Water is necessary only when there is an emission” was a licence granted in the early days of Islam, but that afterwards it was renounced. Tirmidhi, Abu Dawud and Darimi transmitted it.

عَنْ أُبَيِّ بْنِ كَعْبٍ قَالَ: إِنَّمَا كَانَ الْمَاءُ مِنَ الْمَاءِ رُخْصَةً فِي أَوَّلِ الْإِسْلَامِ ثمَّ نهي عَنْهَا

References1 variant
In-Book Reference
Book 3, Hadith 152