<commit_before><?php
namespace Nepf\Response;
use Nepf\Template;

class JSONResponse extends AbstractResponse{
	private $data;
	function __construct($data){
		$this->data = $data;
	}

	public function sendHeaders() {
	}

	public function sendData(){
		echo json_encode($this->data);
	}
}

?><commit_msg>fix: set JSON content-type for JSONResponse<commit_after><?php
namespace Nepf\Response;
use Nepf\Template;

class JSONResponse extends AbstractResponse{
	private $data;
	function __construct($data){
		$this->data = $data;
	}

	public function sendHeaders() {
		header('Content-Type: text/json');
	}

	public function sendData(){
		echo json_encode($this->data);
	}
}

?>
{'fraction_non_alphanumeric': 0.1337295690936107, 'fraction_numerical': 0.0, 'mean_word_length': 5.18348623853211, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4978265', 'n_tokens_mistral': 223, 'n_tokens_neox': 215, 'n_words': 53}