<commit_before><?php

class Ajde extends Ajde_Application
{
}

class Config extends Ajde_Config
{
}

/**
 * The only thing missing in PHP < 5.3
 * In PHP 5.3 you can use: return $test ?: false;
 * This translates in Ajde to return issetor($test);
 *
 * @param      $what
 * @param null $else
 * @return null
 */
function issetor(&$what, $else = null)
{
    // @see http://fabien.potencier.org/article/48/the-php-ternary-operator-fast-or-not
    if (isset($what)) {
        return $what;
    } else {
        return $else;
    }
}

/**
 * @param           $var
 * @param bool|true $expand
 */
function dump($var, $expand = true)
{
    Ajde_Dump::dump($var, $expand);
}

/**
 * Translates the string with Ajde_Lang::translate
 *
 * @param string $ident
 * @param string $module
 * @return string
 */
function __($ident, $module = null)
{
    return Ajde_Lang::getInstance()->translate($ident, $module);
}

/**
 * Escapes the string with Ajde_Component_String::escape
 *
 * @param string $var
 * @return string
 */
function _e($var)
{
    return Ajde_Component_String::escape($var);
}

/**
 * Cleans the string with Ajde_Component_String::clean
 *
 * @param string $var
 * @return string
 */
function _c($var)
{
    return Ajde_Component_String::clean($var);
}<commit_msg>Add config shortcut.<commit_after><?php

class Ajde extends Ajde_Application
{
}

class Config extends Ajde_Config
{
}

/**
 * The only thing missing in PHP < 5.3
 * In PHP 5.3 you can use: return $test ?: false;
 * This translates in Ajde to return issetor($test);
 *
 * @param      $what
 * @param null $else
 * @return null
 */
function issetor(&$what, $else = null)
{
    // @see http://fabien.potencier.org/article/48/the-php-ternary-operator-fast-or-not
    if (isset($what)) {
        return $what;
    } else {
        return $else;
    }
}

/**
 * @param           $var
 * @param bool|true $expand
 */
function dump($var, $expand = true)
{
    Ajde_Dump::dump($var, $expand);
}

/**
 * Translates the string with Ajde_Lang::translate
 *
 * @param string $ident
 * @param string $module
 * @return string
 */
function __($ident, $module = null)
{
    return Ajde_Lang::getInstance()->translate($ident, $module);
}

/**
 * Escapes the string with Ajde_Component_String::escape
 *
 * @param string $var
 * @return string
 */
function _e($var)
{
    return Ajde_Component_String::escape($var);
}

/**
 * Cleans the string with Ajde_Component_String::clean
 *
 * @param string $var
 * @return string
 */
function _c($var)
{
    return Ajde_Component_String::clean($var);
}

/**
 * Shortcut to retrieve config param
 *
 * @param $param
 * @return mixed
 * @throws Ajde_Exception
 */
function config($param)
{
    return Config::get($param);
}
{'fraction_non_alphanumeric': 0.15106853352984526, 'fraction_numerical': 0.004421518054532056, 'mean_word_length': 3.3579454253611556, 'pattern_counts': {'":': 0, '<': 7, '<?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': '2444380', 'n_tokens_mistral': 942, 'n_tokens_neox': 914, 'n_words': 239}