fixed compile error, eliminated duplicate lines