Removed superfluous ifs/whens