Removed redundant IF statments