php-jwt 7 passes the header kid to a ?string parameter, so a token with a
non-string kid throws TypeError before the signature is checked. TypeError
is not an Exception, so validateToken() let it through and the request got a
500. Catch Throwable around JWT::decode() so it is refused like any other
bad token.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>