Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-Authored-By: Jordan Harband <ljharb@gmail.com>
  • Loading branch information
pcorpet and ljharb committed Jan 1, 2020
1 parent e3fa2ce commit 864d99c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rules/extensions.js
Expand Up @@ -156,14 +156,14 @@ module.exports = {
context.report({
node: source,
message:
`Missing file extension ${extension ? `"${extension}" ` : ''}for "${source.value}"`,
`Missing file extension ${extension ? `"${extension}" ` : ''}for "${importPathWithQueryString}"`,
})
}
} else if (extension) {
if (isUseOfExtensionForbidden(extension) && isResolvableWithoutExtension(importPath)) {
context.report({
node: source,
message: `Unexpected use of file extension "${extension}" for "${source.value}"`,
message: `Unexpected use of file extension "${extension}" for "${importPathWithQueryString}"`,
})
}
}
Expand Down

0 comments on commit 864d99c

Please sign in to comment.