The Messenger of Allah (ﷺ) forbade the sale of fruits for dried dates, but gave license regarding the 'araya for its sale on the basis of a calculation of their amount. But those who buy them can eat them when fresh.
Reference: Sunan Abi Dawud 3363 In-book : Book 23, Hadith 38 English translation : Book 22, Hadith 3357
Help us gift a modern, ad-free Islamic application for the Muslim Ummah. Your donation will be recorded as Sadaqah Jariyah in your book of deeds, In Sha Allah.