Fixes #833: added charset to json response.