Specify charset in Content-Type header when returning JSON data from API.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
Chris Down 2013-09-01 16:36:51 +02:00 committed by Lukas Fleischer
parent d225366f31
commit 35c5a5a3a9

View file

@ -43,6 +43,7 @@ class AurJSON {
// overwrite cache-control header set in aur.inc to allow caching, but
// require validation
header('Cache-Control: public, must-revalidate, max-age=0');
header('Content-Type: application/json, charset=utf-8');
// handle error states
if ( !isset($http_data['type']) || !isset($http_data['arg']) ) {