deter them with scents.
fruit flies can't stand the smell of basil, peppermint, eucalyptus, lemongrass, lavender and clove. if you've had a fruit fly problem in the past, try placing these fragrant herbs in muslin sacks or tea bags and hanging them around the house.