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

Check model object in CreateEndpoint to avoid NRE #16243

Merged
merged 1 commit into from
Aug 8, 2024

Conversation

hishamco
Copy link
Member

@hishamco hishamco commented Jun 5, 2024

No description provided.

@hishamco hishamco requested a review from MikeAlhayek June 5, 2024 01:53
@@ -46,6 +46,11 @@ public static IEndpointRouteBuilder AddCreateContentEndpoint(this IEndpointRoute
return httpContext.ChallengeOrForbid("Api");
}

if (model is null)
Copy link
Member

@MikeAlhayek MikeAlhayek Jun 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hishamco in what case will model be null here? I think the binding engine will always create an instance on every request.

Copy link
Contributor

github-actions bot commented Aug 4, 2024

It seems that this pull request didn't really move for quite a while. Is this something you'd like to revisit any time soon or should we close? Please comment if you'd like to pick it up.

@github-actions github-actions bot added the stale label Aug 4, 2024
@sebastienros sebastienros merged commit af518de into main Aug 8, 2024
12 checks passed
@sebastienros sebastienros deleted the hishamco/CreateEndpoint branch August 8, 2024 17:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants