Remove unnecessary return statement from compare