<commit_before><?php

namespace web\ext;

class Widget extends \CWidget
{

    /**
     * Static method to render widget (without specifying of class name)
     *
     * @param array $properties
     * @param type $captureOutput
     */
    public static function create(array $properties = array(), $captureOutput = false)
    {
        \yii::app()->controller->widget(get_called_class(), $properties, $captureOutput);
    }

    /**
     * Create URL
     *
     * @param string $route
     * @param array  $params
     * @param string $ampersand
     * @return string
     */
    public function createUrl($route, array $params = array(), $ampersand = '&')<commit_msg>Fixed widget behavior<commit_after><?php

namespace web\ext;

class Widget extends \CWidget
{

    /**
     * Static method to render widget (without specifying of class name)
     *
     * @param array $properties
     * @param type $captureOutput
     * @return mixed the widget instance when $captureOutput is false, or the widget output when $captureOutput is true
     */
    public static function create(array $properties = array(), $captureOutput = false)
    {
        return \yii::app()->controller->widget(get_called_class(), $properties, $captureOutput);
    }

    /**
     * Create URL
     *
     * @param string $route
     * @param array  $params
     * @param string $ampersand
     * @return string
     */
    public function createUrl($route, array $params = array(), $ampersand = '&')
{'fraction_non_alphanumeric': 0.11848341232227488, 'fraction_numerical': 0.0, 'mean_word_length': 2.7994858611825193, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, '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': '1158103', 'n_tokens_mistral': 412, 'n_tokens_neox': 407, 'n_words': 128}