<commit_before><?php

namespace app\controllers;

use Yii;
use yii\filters\AccessControl;
use yii\helpers\Html;
use app\models\Code;
use app\models\Vote;
use app\models\VoteOption;
use app\models\forms\TokenInputForm;
use app\models\forms\VotingForm;
use app\components\controllers\BaseController;
use yii\web\NotFoundHttpException;
use yii\web\HttpException;
use yii\filters\VerbFilter;
use yii\web\Response;
use yii\widgets\ActiveForm;
use yii\helpers\ArrayHelper;

/**
 * VoteController implements all the actions which are used in the public voting
 */
class VoteController extends BaseController
{

    public $layout = 'voting';
    private $_token = null;


    public function behaviors()
    {
        return [
            'access' => [
                'class' => AccessControl::className(),
                'rules' => [
                    [
                        'actions' => ['index','voting'],
                        'allow' => true,
                    ],
                ],
            ],
            'verbs' => [
                'class' => VerbFilter::className(),
                'actions' => [
                    'logout' => ['post'],
                ],
            ],<commit_msg>testing bjröns filter in votecontroller<commit_after><?php

namespace app\controllers;

use Yii;
use yii\filters\AccessControl;
use yii\helpers\Html;
use app\models\Code;
use app\models\Vote;
use app\models\VoteOption;
use app\models\forms\TokenInputForm;
use app\models\forms\VotingForm;
use app\components\controllers\BaseController;
use app\components\filters\TokenFilter;
use app\components\filters\OpenPollFilter;
use yii\web\NotFoundHttpException;
use yii\web\HttpException;
use yii\filters\VerbFilter;
use yii\web\Response;
use yii\widgets\ActiveForm;
use yii\helpers\ArrayHelper;

/**
 * VoteController implements all the actions which are used in the public voting
 */
class VoteController extends BaseController
{

    public $layout = 'voting';
    private $_token = null;


    public function behaviors()
    {
        return [
            'access' => [
                'class' => AccessControl::className(),
                'rules' => [
                    [
                        'actions' => ['index','voting'],
                        'allow' => true,
                    ],
                ],
            ],
            'verbs' => [
                'class' => VerbFilter::className(),
                'actions' => [
                    'logout' => ['post'],
                ],
            ],
            // 'tokenFilter' => [
            //     'class' => TokenFilter::className(),
            // ],
            // 'openPollFilter' => [
            //     'class' => openPollFilter::className(),
            // ],
{'fraction_non_alphanumeric': 0.12650822669104206, 'fraction_numerical': 0.0, 'mean_word_length': 1.8470343392299688, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 25, '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': '5299763', 'n_tokens_mistral': 776, 'n_tokens_neox': 747, 'n_words': 160}