<commit_before><?php
/**
 * @package     Mautic
 * @copyright   2014 Mautic Contributors. All rights reserved.
 * @author      Mautic
 * @link        http://mautic.org
 * @license     GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
 */

namespace Mautic\InstallBundle\Configurator\Step;

use Mautic\InstallBundle\Configurator\Form\MiscStepType;
use Symfony\Component\Validator\Constraints as Assert;

/**
 * Misc Step.
 */
class MiscStep implements StepInterface
{
    /**
     * Absolute path to cache directory
     *
     * @var string
     * @Assert\NotBlank(message = "mautic.install.notblank")
     */
    public $cache_path = '%kernel.root_dir%/cache';

    /**
     * Absolute path to log directory
     *
     * @var string
     * @Assert\NotBlank(message = "mautic.install.notblank")
     */
    public $log_path   = '%kernel.root_dir%/logs';

    /**
     * Set the domain URL for use in getting the absolute URL for cli/cronjob generated URLs
     *
     * @var string
     */
    public $site_url;

    /**
     * Set the update stability (used when non-stable packages are installed)
     *
     * @var string
     */
    public $update_stability = 'stable';

    /**
     * @var
     */
    private $request_url;

    public function __construct($url)
    {
        $this->request_url = $url;
    }

    /**
     * {@inheritdoc}
     */
    public function getFormType()
    {
        return new MiscStepType($this->request_url);
    }

    /**
     * {@inheritdoc}
     */
    public function checkRequirements()
    {
        return array();
    }

    /**
     * {@inheritdoc}
     */
    public function checkOptionalSettings()
    {
        return array();
    }

    /**
     * {@inheritdoc}
     */
    public function getTemplate()
    {
        return 'MauticInstallBundle:Install:misc.html.php';
    }

    /**
     * {@inheritdoc}
     */
    public function update(StepInterface $data)
    {
        $parameters = array();

        foreach ($data as $key => $value) {
            $parameters[$key] = $value;
        }

        return $parameters;
    }
}<commit_msg>Exclude the request_url from the config<commit_after><?php
/**
 * @package     Mautic
 * @copyright   2014 Mautic Contributors. All rights reserved.
 * @author      Mautic
 * @link        http://mautic.org
 * @license     GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
 */

namespace Mautic\InstallBundle\Configurator\Step;

use Mautic\InstallBundle\Configurator\Form\MiscStepType;
use Symfony\Component\Validator\Constraints as Assert;

/**
 * Misc Step.
 */
class MiscStep implements StepInterface
{
    /**
     * Absolute path to cache directory
     *
     * @var string
     * @Assert\NotBlank(message = "mautic.install.notblank")
     */
    public $cache_path = '%kernel.root_dir%/cache';

    /**
     * Absolute path to log directory
     *
     * @var string
     * @Assert\NotBlank(message = "mautic.install.notblank")
     */
    public $log_path   = '%kernel.root_dir%/logs';

    /**
     * Set the domain URL for use in getting the absolute URL for cli/cronjob generated URLs
     *
     * @var string
     */
    public $site_url;

    /**
     * Set the update stability (used when non-stable packages are installed)
     *
     * @var string
     */
    public $update_stability = 'stable';

    /**
     * @var
     */
    private $request_url;

    public function __construct($url)
    {
        $this->request_url = $url;
    }

    /**
     * {@inheritdoc}
     */
    public function getFormType()
    {
        return new MiscStepType($this->request_url);
    }

    /**
     * {@inheritdoc}
     */
    public function checkRequirements()
    {
        return array();
    }

    /**
     * {@inheritdoc}
     */
    public function checkOptionalSettings()
    {
        return array();
    }

    /**
     * {@inheritdoc}
     */
    public function getTemplate()
    {
        return 'MauticInstallBundle:Install:misc.html.php';
    }

    /**
     * {@inheritdoc}
     */
    public function update(StepInterface $data)
    {
        $parameters = array();

        foreach ($data as $key => $value) {
            // Exclude backup params from the config
            if ($key != 'request_url') {
                $parameters[$key] = $value;
            }
        }

        return $parameters;
    }
}
{'fraction_non_alphanumeric': 0.12817551963048499, 'fraction_numerical': 0.003233256351039261, 'mean_word_length': 2.001386001386001, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '5008698', 'n_tokens_mistral': 1355, 'n_tokens_neox': 1316, 'n_words': 290}