Closed naumanpathan closed 4 years ago
I have fixed this issue by using 5 new files and link those files into JWT.php. Plugin code was for a temporary solution so i fixed plugin code to meet requirements
The solution is:
create one folder with the name of Exception
Add tree exception files into the Exception folder
<?php
namespace AppleSignIn\Vendor\Exception;
/**
1. ExpiredException.php
```php
<?php
namespace AppleSignIn\Vendor\Exception;
/**
3. SignatureInvalidException.php
```php
<?php
namespace AppleSignIn\Vendor\Exception;
/**
* Class SignatureInvalidException
*/
class SignatureInvalidException extends InvalidJwtException
{
}
<?php
namespace AppleSignIn\Vendor\Exception;
/**
5. Exception.php
```php
<?php
namespace AppleSignIn\Vendor\Exception;
/**
Then use it in JWT.php
use AppleSignIn\Vendor\Exception\BeforeValidException;
use AppleSignIn\Vendor\Exception\ExpiredException;
use AppleSignIn\Vendor\Exception\SignatureInvalidException;
i referred from php-jwt.
Thank you.
Hello, I have tried this plugin in my Yii2 project and unfortunately, I get the error regarding the exception. And in my case, I get the errors with the following exceptions from vendor:
The JWT.php code file image reference![image](https://user-images.githubusercontent.com/47807923/74009785-f5c74780-49a9-11ea-8290-db81eb4177dc.png)
Error image reference![image](https://user-images.githubusercontent.com/47807923/74009416-235fc100-49a9-11ea-91b4-684c262e7d42.png)