removed duped statements. Thanks @wgx731