Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CC0013 Should be Information instead of Warning #520

Closed
paulomorgado opened this issue Sep 22, 2015 · 2 comments
Closed

CC0013 Should be Information instead of Warning #520

paulomorgado opened this issue Sep 22, 2015 · 2 comments
Assignees
Milestone

Comments

@paulomorgado
Copy link

Sometimes, it makes sense and the code is more readable as an if/else instead of a ternary operator.

One such cases is when there's an execution flow that happens to return a value:

if (this.Url.IsLocalUrl(returnUrl))
{
    return this.Redirect(returnUrl);
}
else
{
    return this.RedirectToAction("Index");
}

I want to see that it's following different branches and not just return one of two possible values.

@giggio
Copy link
Member

giggio commented Sep 30, 2015

Makes sense to me.

@giggio giggio self-assigned this Sep 30, 2015
@giggio giggio added this to the 1.0.0 milestone Sep 30, 2015
@giggio
Copy link
Member

giggio commented Sep 30, 2015

I will also be changing CC0014 as the argument is the same there.

@giggio giggio closed this as completed in ae594ee Sep 30, 2015
jwooley pushed a commit to jwooley/code-cracker that referenced this issue Nov 4, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants