diff --git a/lib/less/parser.js b/lib/less/parser.js index ab537016..eda203c3 100644 --- a/lib/less/parser.js +++ b/lib/less/parser.js @@ -155,14 +155,14 @@ less.Parser = function Parser(env) { } } + this.env = env || {}; // The optimization level dictates the thoroughness of the parser, // the lower the number, the less nodes it will create in the tree. // This could matter for debugging, or if you want to access // the individual nodes in the tree. - this.optimization = 2; + this.optimization = this.env.optimization || 2; - this.env = env || {}; // // The Parser