Remove duplicate code in bower ignore manager