Skip to content

Conversation

bartizan
Copy link
Contributor

…al permission check #1419

@bartizan bartizan marked this pull request as ready for review October 10, 2025 11:08
@bartizan bartizan requested a review from a team as a code owner October 10, 2025 11:08
@waldekmastykarz
Copy link
Collaborator

Thanks for the PR! We'll review it asap

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds error logging for missing Authorization headers during minimal permission checks to improve debugging and user feedback. The change prevents potential runtime exceptions that could occur when the Authorization header is absent.

  • Replaced direct header access with safe null-checking using FirstOrDefault()
  • Added explicit error logging when no Authorization header is found
  • Maintained existing functionality while improving error handling

Copy link
Collaborator

@waldekmastykarz waldekmastykarz left a comment

Choose a reason for hiding this comment

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

Good catch. No further comments.

@waldekmastykarz waldekmastykarz merged commit 3950d07 into dotnet:main Oct 17, 2025
4 checks passed
@bartizan bartizan deleted the 1419_not-found-auth-header-error branch October 17, 2025 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add error logging for a missing Authorization header during the minimal permission check

2 participants