Refactor private PushAuthorizationRequest by marcusber · Pull Request #59990 · dotnet/aspnetcore (original) (raw)

Refactor private PushAuthorizationRequest

An exception was created but not thrown. Make relevant changes to remove that.

Description

An exception was created but not thrown. When backtracking the usage of the private method, the PAR-endpoint was already guarded for empty PAR-enpoints.
Pass in the PAR-endpoint as non-null reference to the private method. Remove the exception that was created and not thrown.

Existing unit tests never reaches the private method due to guards in the calling method.

I'm not sure which branch this PR should target. It should be compatible with main when cherry-picked.