removed redundant if clause