removed redundant json_encode