From 9d79769d1d91eb5e83fde8daff2f34d77f1b4345 Mon Sep 17 00:00:00 2001 From: Lee Byron Date: Thu, 26 Jan 2017 16:32:31 -0800 Subject: [PATCH] Minor var renaming --- index.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/index.js b/index.js index 08de2b4..0a8594e 100644 --- a/index.js +++ b/index.js @@ -220,7 +220,7 @@ function removeNode(context, node) { var length = removedNodes.length; var index = length; - // Check for line's trailing space to be removed. + // Check for line's leading and trailing space to be removed. var spaceNode = context.pretty ? getLeadingSpaceNode(context, node) : null; var lineNode = context.pretty ? getTrailingLineNode(context, node) : null; @@ -253,8 +253,8 @@ function removeNode(context, node) { return false; } -function getLeadingSpaceNode(state, node) { - var source = state.source; +function getLeadingSpaceNode(context, node) { + var source = context.source; var end = node.start; var start = end; while (source[start - 1] === ' ' || source[start - 1] === '\t') { @@ -269,8 +269,8 @@ function getLeadingSpaceNode(state, node) { } } -function getTrailingLineNode(state, node) { - var source = state.source; +function getTrailingLineNode(context, node) { + var source = context.source; var start = node.end; var end = start; while (source[end] === ' ' || source[end] === '\t') {