educoder/pest — pull request #53 by sandfox-im (2014-05-07 13:56:37+00:00)
Title: Decode failure detection is incorrect in PestJSON

* json_decode returns NULL not FALSE on decode failure
* NULL and FALSE are also returned for their valid json counterparts so we also need to check for errors (this also makes failure detection in php < 5.3 a challenge)

>>> json_decode('null')
=> null
>>> json_decode('false')
=> false