This is a tip that my grandmother taught me when I was little and I still use it to this day. I hope you find it helpful too!
To get rid of pesky fruit flies, try this simple trick: Fill a small glass or empty jelly jar 1/2 full with Apple Cider Vinegar. Add 2 drops of dish washing liquid, and mix well. With a jelly jar, you can just put the lid on and shake it! Leave the liquid standing somewhere in your kitchen where it’s not likely to get knocked over and take the lid off. You’ll find that fruit flies are naturally drawn to the jar (and unable to leave).
Apple cider vinegar, dish soap, and water makes a great organic insecticide so after use as a bug trap, add a little water and empty the liquid into a flower bed or potted plant, and start again!