Pour vegetable or olive oil in your kitchen sink. This will catch any gnats that hang around the drain or garbage disposal. The gnats will fly into the oil but will be either unable to free themselves from it, or simply unable to mate afterward, as they are coated in the oil. You may need to repeat this process several times to get all of the gnats, but it is very effective.
Get rid of gnats in your home and keep them away for good!