<commit_before><commit_msg>Adding patched for json<commit_after>package com.farmafene.cas;

import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.jasig.cas.validation.Assertion;
import org.jasig.cas.validation.ImmutableAssertion;
import org.jasig.cas.web.view.Cas30JsonResponseView;

public class Cas30ResponseViewPatched extends Cas30JsonResponseView {

	private static final String ASSERTION = "assertion";

	public Cas30ResponseViewPatched() {
	}

	/**
	 * {@inheritDoc}
	 * 
	 * @see org.jasig.cas.web.view.Cas30JsonResponseView#prepareMergedOutputModel(java.util.Map,
	 *      javax.servlet.http.HttpServletRequest,
	 *      javax.servlet.http.HttpServletResponse)
	 */
	@Override
	protected void prepareMergedOutputModel(Map<String, Object> model, HttpServletRequest request,
			HttpServletResponse response) throws Exception {
		Assertion assertion = (Assertion) model.get(ASSERTION);
		if (assertion != null && assertion.getChainedAuthentications() != null
				&& assertion.getChainedAuthentications().size() > 0) {
			ImmutableAssertion is = new ImmutableAssertion(assertion.getChainedAuthentications().get(0),
					assertion.getChainedAuthentications(), assertion.getService(), assertion.isFromNewLogin());
			model.put(ASSERTION, is);
		}
		super.prepareMergedOutputModel(model, request, response);
	}

}
{'fraction_non_alphanumeric': 0.1079913606911447, 'fraction_numerical': 0.008639308855291577, 'mean_word_length': 5.747572815533981, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 5, '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': '5453304', 'n_tokens_mistral': 446, 'n_tokens_neox': 414, 'n_words': 70}