Remove redundant equality check