<commit_before><?php

/**
 * Description of users_management
 *
 * @author desarrollo
 */
class users_management extends Public_Controller {

    /**
     * Validation for basic profile
     * data. The rest of the validation is
     * built by streams.
     *
     * @var array
     */
    private $validation_rules = array(
        'email' => array(
            'field' => 'email',
            'label' => 'lang:global:email',
            'rules' => 'required|max_length[60]|valid_email'
        ),
        'password' => array(
            'field' => 'password',
            'label' => 'lang:global:password',
            'rules' => 'min_length[6]|max_length[20]'
        ),
        'username' => array(
            'field' => 'username',
            'label' => 'lang:user_username',
            'rules' => 'required|alpha_dot_dash|min_length[3]|max_length[20]'
        ),
        array(
            'field' => 'active',
            'label' => 'lang:user_active_label',
            'rules' => ''
        ),
        array(
            'field' => 'display_name',
            'label' => 'lang:profile_display_name',
            'rules' => 'required'
        )
    );

    /**
     * Class construct
     */
    public function __construct() {
        parent::__construct();
        $this->lang->load('users_management');
        $this->load->model('users/user_m');
        $this->load->model('users/profile_m');
        $this->load->model('groups/group_m');
        $this->load->helper('user');
        $this->load->library('form_validation');
        $this->lang->load('users/user');

        if ($this->current_user->group != 'admin') {
            $this->template->groups = $this->group_m->where_not_in('name', 'admin')->get_all();
        } else {
            $this->template->groups = $this->group_m->get_all();
        }

        $this->template->groups_select = array_for_select($this->template->groups, 'id', 'description');
        $this->template->append_js('module::users_management.js', null, 'modules');
    }

    /**
     * List the users
     */
    public function index() {<commit_msg>protected<commit_after><?php

/**
 * Description of users_management
 *
 * @author desarrollo
 */
class users_management extends Public_Controller {

    /**
     * Validation for basic profile
     * data. The rest of the validation is
     * built by streams.
     *
     * @var array
     */
    private $validation_rules = array(
        'email' => array(
            'field' => 'email',
            'label' => 'lang:global:email',
            'rules' => 'required|max_length[60]|valid_email'
        ),
        'password' => array(
            'field' => 'password',
            'label' => 'lang:global:password',
            'rules' => 'min_length[6]|max_length[20]'
        ),
        'username' => array(
            'field' => 'username',
            'label' => 'lang:user_username',
            'rules' => 'required|alpha_dot_dash|min_length[3]|max_length[20]'
        ),
        array(
            'field' => 'active',
            'label' => 'lang:user_active_label',
            'rules' => ''
        ),
        array(
            'field' => 'display_name',
            'label' => 'lang:profile_display_name',
            'rules' => 'required'
        )
    );

    /**
     * Class construct
     */
    public function __construct() {
        ci()->secure = true;
        parent::__construct();
        $this->lang->load('users_management');
        $this->load->model('users/user_m');
        $this->load->model('users/profile_m');
        $this->load->model('groups/group_m');
        $this->load->helper('user');
        $this->load->library('form_validation');
        $this->lang->load('users/user');

        if ($this->current_user->group != 'admin') {
            $this->template->groups = $this->group_m->where_not_in('name', 'admin')->get_all();
        } else {
            $this->template->groups = $this->group_m->get_all();
        }

        $this->template->groups_select = array_for_select($this->template->groups, 'id', 'description');
        $this->template->append_js('module::users_management.js', null, 'modules');
    }

    /**
     * List the users
     */
    public function index() {
{'fraction_non_alphanumeric': 0.1760113555713272, 'fraction_numerical': 0.003785190442394133, 'mean_word_length': 2.0704429920116194, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 102, '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': '4603864', 'n_tokens_mistral': 1251, 'n_tokens_neox': 1230, 'n_words': 204}