On the day of Khaiber, Allah's Messenger (ﷺ) forbade the eating of garlic and the meat of donkeys.
Sahih al-Bukhari Book 64, Hadith 255