Ibn 'Umar (RA) reported Allah's Apostle (ﷺ) as saying: Whosoever grafts the tree and then sells its roots, its fruit will belong to one who grafts it except when provision is laid down by the buyer.
Hadith ReferenceSahih Muslim / The Book of Transactions / Hadith: 1543