From 49c12681570f0bab6b0952b71b49fedade205873 Mon Sep 17 00:00:00 2001 From: Kevin DeJong Date: Tue, 10 Jul 2018 10:39:59 -0500 Subject: [PATCH] lint new code --- lib/atom-cfn-lint.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/lib/atom-cfn-lint.js b/lib/atom-cfn-lint.js index 2080c43..884bdf9 100644 --- a/lib/atom-cfn-lint.js +++ b/lib/atom-cfn-lint.js @@ -42,7 +42,6 @@ const makeIdleCallback = (work) => { const scheduleIdleTasks = () => { const linterAtomCfnLintInstallPeerPackages = () => { - console.log('test') require('atom-package-deps').install('atom-cfn-lint') } const linterAtomCfnLintStartWorker = () => { @@ -197,17 +196,17 @@ module.exports = { const linenumberend = parseInt(match.Location.End.LineNumber, 10) - 1 const columnnumberend = parseInt(match.Location.End.ColumnNumber, 10) - 1 - souce_url = ""; + let sourceUrl = '' // Rule sources are added in version 0.3.3 of cfn-lint - if (match.Rule.hasOwnProperty('Source')) { - souce_url = match.Rule.Source.toLowerCase() + if (Object.prototype.hasOwnProperty.call(match.Rule, 'Source')) { + sourceUrl = match.Rule.Source.toLowerCase() } toReturn.push({ severity: match.Level.toLowerCase(), excerpt: match.Message, - url: souce_url, + url: sourceUrl, location: { file, position: [[linenumber, columnnumber], [linenumberend, columnnumberend]],