Request.type typo fixed and json_data var bug fixed.