Skip to content

Latest commit

 

History

History
50 lines (36 loc) · 1.22 KB

ASP008.md

File metadata and controls

50 lines (36 loc) · 1.22 KB

ASP008

Invalid route parameter name

Topic Value
Id ASP008
Severity Warning
Enabled True
Category AspNetCoreAnalyzers.Routing
Code AttributeAnalyzer

Description

Invalid route parameter name.

Motivation

ADD MOTIVATION HERE

How to fix violations

ADD HOW TO FIX VIOLATIONS HERE

Configure severity

Via ruleset file.

Configure the severity per project, for more info see MSDN.

Via #pragma directive.

#pragma warning disable ASP008 // Invalid route parameter name
Code violating the rule here
#pragma warning restore ASP008 // Invalid route parameter name

Or put this at the top of the file to disable all instances.

#pragma warning disable ASP008 // Invalid route parameter name

Via attribute [SuppressMessage].

[System.Diagnostics.CodeAnalysis.SuppressMessage("AspNetCoreAnalyzers.Routing", 
    "ASP008:Invalid route parameter name", 
    Justification = "Reason...")]