took out duplicate code