mirror of
https://github.com/less/less.js.git
synced 2026-04-09 03:00:20 -04:00
Tidy Import Visitor arguments
This commit is contained in:
@@ -2,24 +2,16 @@ var contexts = require("../contexts"),
|
||||
Visitor = require("./visitor"),
|
||||
ImportSequencer = require("./import-sequencer");
|
||||
|
||||
var ImportVisitor = function(importer, finish, evalEnv, onceFileDetectionMap, recursionDetector) {
|
||||
// TODO arguments not all necessary now
|
||||
var ImportVisitor = function(importer, finish) {
|
||||
|
||||
this._visitor = new Visitor(this);
|
||||
this._importer = importer;
|
||||
this._finish = finish;
|
||||
// TODO probably doesnt need to be an array
|
||||
this.contextStack = [evalEnv || new contexts.Eval()];
|
||||
this.contextStack = [new contexts.Eval()];
|
||||
this.importCount = 0;
|
||||
this.onceFileDetectionMap = onceFileDetectionMap || {};
|
||||
this.onceFileDetectionMap = {};
|
||||
this.recursionDetector = {};
|
||||
if (recursionDetector) {
|
||||
for(var fullFilename in recursionDetector) {
|
||||
if (recursionDetector.hasOwnProperty(fullFilename)) {
|
||||
this.recursionDetector[fullFilename] = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
this._sequencer = new ImportSequencer();
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user