Jamm\Memory\Tests\CommandsListCheck::getDocFromJSON PHP Метод

getDocFromJSON() защищенный Метод

protected getDocFromJSON ( $json )
    protected function getDocFromJSON($json)
    {
        if (empty($json)) {
            $json = $this->downloadJSON();
        }
        $doc = json_decode($json, true);
        if (json_last_error() > 0) {
            throw new \Exception('wrong json');
        }
        return $doc;
    }