This PR adds a different error messages to differentiate between failing to find a public key (when the request to get the key set fails) vs when there isn't a public key matching the JWT. This is to clarify exactly what is causing the error Unable to find public key., which was previously being thrown in two places.
Testing
I copy+pasted my changes to the backend vendor code and verified that, by forcing that exception to be thrown, the error is displayed as expected. I also verified that debugging can be toggled on the service connector by passing true in for the last parameter.
[ ] I have added automated tests for my changes
[X] I ran composer test before opening this PR
[X] I ran composer lint-fix before opening this PR
Summary of Changes
This PR adds a different error messages to differentiate between failing to find a public key (when the request to get the key set fails) vs when there isn't a public key matching the JWT. This is to clarify exactly what is causing the error
Unable to find public key.
, which was previously being thrown in two places.Testing
I copy+pasted my changes to the backend vendor code and verified that, by forcing that exception to be thrown, the error is displayed as expected. I also verified that debugging can be toggled on the service connector by passing
true
in for the last parameter.composer test
before opening this PRcomposer lint-fix
before opening this PR