Skip to content
This repository has been archived by the owner on Oct 19, 2021. It is now read-only.

Commit

Permalink
Prevent CoffeeLint from blowing up when package.json can't be parsed
Browse files Browse the repository at this point in the history
  • Loading branch information
AsaAyers committed Mar 29, 2015
1 parent b71c98c commit 61615c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/configfinder.coffee
Expand Up @@ -26,7 +26,7 @@ findFile = (name, dir) ->
# Possibly find CoffeeLint configuration within a package.json file.
loadNpmConfig = (dir) ->
fp = findFile("package.json", dir)
loadJSON(fp).coffeelintConfig if fp
loadJSON(fp)?.coffeelintConfig if fp

# Parse a JSON file gracefully.
loadJSON = (filename) ->
Expand Down

0 comments on commit 61615c2

Please sign in to comment.