Skip to content
This repository was archived by the owner on Aug 30, 2025. It is now read-only.

Commit 27b1ad5

Browse files
committed
refactor: Remove redundant code
1 parent bfeac44 commit 27b1ad5

1 file changed

Lines changed: 0 additions & 4 deletions

File tree

src/ApiProblemDetailsFactory.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,6 @@ public override ProblemDetails CreateProblemDetails(
124124
string instance = null
125125
)
126126
{
127-
statusCode ??= httpContext.GetStatusCode();
128-
129127
var problemDetails = new ProblemDetails
130128
{
131129
Status = statusCode,
@@ -155,8 +153,6 @@ public override ValidationProblemDetails CreateValidationProblemDetails(
155153
throw new ArgumentNullException(nameof(modelStateDictionary));
156154
}
157155

158-
statusCode ??= httpContext.GetStatusCode();
159-
160156
var problemDetails = new ValidationProblemDetails(modelStateDictionary)
161157
{
162158
Status = statusCode,

0 commit comments

Comments
 (0)