Skip to content

Commit

Permalink
Merge pull request #506 from Gillespie59/development
Browse files Browse the repository at this point in the history
3.1.1
  • Loading branch information
EmmanuelDemey authored Aug 30, 2017
2 parents 7739546 + dfed97f commit a093afe
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eslint-plugin-angular",
"version": "3.1.0",
"version": "3.1.1",
"description": "ESLint rules for AngularJS projects",
"main": "index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion rules/file-name.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ function handleModuleCase(node, context, defaultFilename) {
});

// Check that the definition is an import declaration.
if (variable.defs[0].parent.type !== 'ImportDeclaration') {
if (!(variable && variable.defs && variable.defs[0] && variable.defs[0].parent && variable.defs[0].parent.type === 'ImportDeclaration')) {
return defaultFilename;
}

Expand Down

0 comments on commit a093afe

Please sign in to comment.