Garbage flies are extremely unsanitary, as they feed on dead matter and other decaying organic material. There are several methods to getting rid of garbage flies, such as luring them into a canister with vinegar or a similar concoction, and also bating them with other decaying matter. Above everything else, it is extremely important to clean up any messes or decaying food matter that could harbor the infestation. It is possible to make a trap as well as clean with vinegar. The apple cider vinegar can be used to lure the flies into a trap, while regular white vinegar with a bit of water can be mixed to make a cleaning solution that strips away food or odor that is attracting the garbage flies.