You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Use InvalidArgumentException when $allowed_algs is not array
> Exception thrown if an argument is not of the expected type.
http://php.net/manual/en/class.invalidargumentexception.php
* Use RuntimeExceptions for exceptions related with unencoded data.
RuntimeExceptions is the correct exception error source is the decoded data.
Note LogicExceptions as defined in PHP documentation implies a modification in the code by the developer.
> Exception that represents error in the program logic. This kind of exception should lead directly to a fix in your code.
http://php.net/manual/en/class.logicexception.php
But the token is a data provided by an external source which is out side of the control of the developer so there is no way of prevent malformed tokens.
0 commit comments