linter.js
function lintMethod (mtd, file, config, cb, configPath) {
	let runConfig = transformConfig(config);

	if (typeof cb !== 'function') {
		cb = function () {};
	}

	try {
		let results = sassLint[mtd](file, runConfig, configPath);

		if (mtd !== 'lintFiles') {
			if (!Array.isArray(results)) {
				results = [results];
			}
		}

		let data = {
			results,
			errorCount: sassLint.errorCount(results),
			warningCount: sassLint.warningCount(results)
		};

		cb(null, data);
	} catch (err) {
		cb(err);
	}
}
function lintMethod (mtd, file, config, cb, configPath) {
	let runConfig = transformConfig(config);

	if (typeof cb !== 'function') {
		cb = function () {};
	}

	try {
		let results = sassLint[mtd](file, runConfig, configPath);

		if (mtd !== 'lintFiles') {
			if (!Array.isArray(results)) {
				results = [results];
			}
		}

		let data = {
			results,
			errorCount: sassLint.errorCount(results),
			warningCount: sassLint.warningCount(results)
		};

		cb(null, data);
	} catch (err) {
		cb(err);
	}
}
function lintMethod ( mtd , file , config , cb , configPath ) { let runConfig = transformConfig ( config ) ; if ( typeof cb !== 'function' ) { cb = function ( ) { } ; } try { let results = sassLint [ mtd ] ( file , runConfig , configPath ) ; if ( mtd !== 'lintFiles' ) { if ( ! Array . isArray ( results ) ) { results = [ results ] ; } } let data = { results , errorCount : sassLint . errorCount ( results ) , warningCount : sassLint . warningCount ( results ) } ; cb ( null , data ) ; } catch ( err ) { cb ( err ) ; } }
Creating linting methods with happiness-scss configPath
@param {string} mtd
@param {string} file
@param {Object} [config]
@param {function} [cb]
@param {string} configPath
Creating linting methods with happiness - scss configPath