Skip to content

Commit

Permalink
jshint: boss
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeapage committed Dec 16, 2013
1 parent 4f7c06c commit 3818727
Show file tree
Hide file tree
Showing 16 changed files with 214 additions and 134 deletions.
4 changes: 2 additions & 2 deletions .jshintrc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"evil": true,
"boss": true,
"laxbreak": true,
"latedef": true,
"node": true,
"undef": true,
"unused": "vars",
"noarg": true
"noarg": true,
"eqnull": true
}
5 changes: 3 additions & 2 deletions lib/less/browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -615,10 +615,11 @@ less.watch = function () {
less.env = 'development';
initRunningMode();
}
return this.watchMode = true;
this.watchMode = true;
return true;
};

less.unwatch = function () {clearInterval(less.watchTimer); return this.watchMode = false; };
less.unwatch = function () {clearInterval(less.watchTimer); this.watchMode = false; return false; };

if (/!watch/.test(location.hash)) {
less.watch();
Expand Down
2 changes: 0 additions & 2 deletions lib/less/functions.js
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,6 @@ tree.functions = {
},
_math: function (fn, unit, n) {
if (n instanceof tree.Dimension) {
/*jshint eqnull:true */
return new(tree.Dimension)(fn(parseFloat(n.value)), unit == null ? n.unit : unit);
} else if (typeof(n) === 'number') {
return fn(n);
Expand Down Expand Up @@ -565,7 +564,6 @@ var mathFunctions = [{name:"ceil"}, {name:"floor"}, {name: "sqrt"}, {name:"abs"}
{name:"atan", unit: "rad"}, {name:"asin", unit: "rad"}, {name:"acos", unit: "rad"}],
createMathFunction = function(name, unit) {
return function(n) {
/*jshint eqnull:true */
if (unit != null) {
n = n.unify();
}
Expand Down
3 changes: 2 additions & 1 deletion lib/less/join-selector-visitor.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@
this.contexts.push(paths);

if (! rulesetNode.root) {
if (selectors = rulesetNode.selectors) {
selectors = rulesetNode.selectors;
if (selectors) {
selectors = selectors.filter(function(selector) { return selector.getIsOutput(); });
rulesetNode.selectors = selectors.length ? selectors : (selectors = null);
if (selectors) { rulesetNode.joinSelectors(paths, context, selectors); }
Expand Down
Loading

0 comments on commit 3818727

Please sign in to comment.