Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the proper Exception message for all JSON error types by PHP #110

Merged
merged 3 commits into from
Jun 21, 2017
Merged

Add the proper Exception message for all JSON error types by PHP #110

merged 3 commits into from
Jun 21, 2017

Conversation

gbalduzzi
Copy link

@gbalduzzi gbalduzzi commented Sep 17, 2016

Related to issue #99 Unknown JSON error

json_last_error_msg() is not used because it would break compatibility with PHP < 5.5.
This solution supports all error types until 5.5, keeping compatibility with previous versions.

@T3RON
Copy link

T3RON commented Jun 6, 2019

**> please send me JWT.php fixed for CodeIgniter ...!

seif4847@gmail.com**

my error :

An uncaught Exception was encountered

Type: DomainException

Message: Unknown JSON error: 5

Filename: F:\wamp64\www\fzm\application\helpers\jwt_helper.php

Line Number: 201

Backtrace:

File: F:\wamp64\www\fzm\application\helpers\jwt_helper.php
Line: 132
Function: _handleJsonError

File: F:\wamp64\www\fzm\application\helpers\jwt_helper.php
Line: 42
Function: jsonDecode

File: F:\wamp64\www\fzm\application\helpers\authorization_helper.php
Line: 18
Function: decode

File: F:\wamp64\www\fzm\application\controllers\api\ApiPost.php
Line: 78
Function: validateToken

File: F:\wamp64\www\fzm\application\libraries\REST_Controller.php
Line: 785
Function: call_user_func_array

File: F:\wamp64\www\fzm\index.php
Line: 315
Function: require_once

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants