<commit_before><?php


/**
 * @author <NAME>, webtischlerei
 * @copyright Copyright &copy; 2011, webtischlerei
 * @author <NAME>, w3concepts AG
 * @copyright Copyright &copy; 2011, w3concepts AG
 */
class Module_Search_Lucene_Class extends Aitsu_Module_Abstract {

	protected function _init() {

		Aitsu_Content_Edit :: noEdit('Search.Lucene', true);

		Aitsu_Registry :: setExpireTime(0);

		$searchterm = $_REQUEST['searchterm'];

		$view = $this->_getView();

		$view->searchterm = $searchterm;

		$search_area = Aitsu_Config :: get('search.lucene.area');

		$search_array = array ();
		foreach ($search_area as $idcat) {
			$search_array[] = $idcat;
		}

		try {
			$view->results = Aitsu_Lucene_Index :: find($searchterm, $search_array);
		} catch (Exception $e) {
			$view->results = array ();
		}

		$output = $view->render('index.phtml');

		return $output;
	}
<commit_msg>minor "Search_Lucene" module changes<commit_after><?php

/**
 * @author <NAME>, webtischlerei
 * @copyright Copyright &copy; 2011, webtischlerei
 * @author <NAME>, w3concepts AG
 * @copyright Copyright &copy; 2011, w3concepts AG
 */
class Module_Search_Lucene_Class extends Aitsu_Module_Abstract {

    protected $_allowEdit = false;

    protected function _init() {

        Aitsu_Registry::setExpireTime(0);

        $searchterm = $_REQUEST['searchterm'];

        $search_area = Aitsu_Config::get('search.lucene.area');

        $search_array = array();
        foreach ($search_area as $idcat) {
            $search_array[] = $idcat;
        }

        $view = $this->_getView();
        $view->searchterm = $searchterm;

        try {
            $view->results = Aitsu_Lucene_Index::find($searchterm, $search_array);
        } catch (Exception $e) {
            trigger_error($e->getMessage());
            $view->results = array();
        }

        return $view->render('index.phtml');
    }

{'fraction_non_alphanumeric': 0.14657461497610197, 'fraction_numerical': 0.01168348380244291, 'mean_word_length': 3.4018691588785046, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 18, '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': '2262426', 'n_tokens_mistral': 666, 'n_tokens_neox': 595, 'n_words': 123}