<commit_before>"use strict";

/**
 * @typedef {{
 *      input: string,
 *      output: string,
 *      browsers: string[],
 * }} ScssTaskConfig
 *
 * @typedef {{
 *      srcDir: string,
 *      browsers: string[],
 *      output: string,
 * }} InternalScssTaskConfig
 */

const fs = require("fs-extra");
const ScssTask = require("./scss/scss-task");
const _ = require("lodash");
const path = require("path");




/**
 * Main task for Sass
 *
 * @param {ScssTaskConfig} config
 *
 * @returns {Function}
 */
module.exports = function (config)
{
    // parse user config
    config = _.assign({
        input: "src/**/Resources/assets/scss/",
        output: "../../public/css",
        browsers: ["last 2 versions", "IE 10"]
    }, config);

    // build internal config
    var srcDir = config.input.replace(/\/+$/, "") + "/";

    /** @var internalConfig {InternalScssTaskConfig}  */
    let internalConfig = {
        // ensure exactly one slash at the end
        srcDir: srcDir,
        browsers: config.browsers,
        output: config.output
    };

    return function (done, debug)
    {
        let task = new ScssTask(internalConfig);
        task.run(done, debug);
    }
};<commit_msg>Fixed default value and type declaration<commit_after>"use strict";

/**
 * @typedef {{
 *      input: string,
 *      output: string,
 *      browsers: string[],
 * }} ScssTaskConfig
 *
 * @typedef {{
 *      srcDir: string,
 *      browsers: string[],
 *      output: string,
 * }} InternalScssTaskConfig
 */

const fs = require("fs-extra");
const ScssTask = require("./scss/scss-task");
const _ = require("lodash");
const path = require("path");




/**
 * Main task for Sass
 *
 * @param {ScssTaskConfig} config
 *
 * @returns {Function}
 */
module.exports = function (config = {})
{
    // parse user config
    config = _.assign({
        input: "src/**/Resources/assets/scss/",
        output: "../../public/css",
        browsers: ["last 2 versions", "IE 10"]
    }, config);

    // build internal config
    var srcDir = config.input.replace(/\/+$/, "") + "/";

    /** @var {InternalScssTaskConfig} internalConfig */
    let internalConfig = {
        // ensure exactly one slash at the end
        srcDir: srcDir,
        browsers: config.browsers,
        output: config.output
    };

    return function (done, debug)
    {
        let task = new ScssTask(internalConfig);
        task.run(done, debug);
    }
};
{'fraction_non_alphanumeric': 0.16302104828724723, 'fraction_numerical': 0.0024762690879075525, 'mean_word_length': 2.39020979020979, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '184778', 'n_tokens_mistral': 764, 'n_tokens_neox': 746, 'n_words': 187}