eslint-plugin-ember
Advanced tools
Comparing version 6.0.0 to 6.0.1
# Changelog | ||
## v6.0.1 (2018-11-16) | ||
#### :rocket: Enhancement | ||
* [#331](https://github.com/ember-cli/eslint-plugin-ember/pull/331) Updating no-side-effects to also report on setProperties. ([@gmurphey](https://github.com/gmurphey)) | ||
#### :bug: Bug Fix | ||
* [#340](https://github.com/ember-cli/eslint-plugin-ember/pull/340) no-restricted-resolver: Fix crashes ([@Turbo87](https://github.com/Turbo87)) | ||
#### :house: Internal | ||
* [#335](https://github.com/ember-cli/eslint-plugin-ember/pull/335) Remove outdated `.nvmrc` file ([@Turbo87](https://github.com/Turbo87)) | ||
* [#334](https://github.com/ember-cli/eslint-plugin-ember/pull/334) package.json: Limit published files to the `lib` folder ([@Turbo87](https://github.com/Turbo87)) | ||
* [#336](https://github.com/ember-cli/eslint-plugin-ember/pull/336) CI: Use `--runInBand` option of Jest to speed up tests ([@Turbo87](https://github.com/Turbo87)) | ||
#### Committers: 2 | ||
- Garrett Murphey ([@gmurphey](https://github.com/gmurphey)) | ||
- Tobias Bieniek ([@Turbo87](https://github.com/Turbo87)) | ||
## v6.0.0 (2018-11-14) | ||
@@ -4,0 +22,0 @@ |
@@ -95,5 +95,3 @@ 'use strict'; | ||
].forEach((fn) => { | ||
visitors[`Identifier[name="${fn}"]`] = function (node) { | ||
const lastArgument = getLastArgument(node); | ||
visitors[`CallExpression > Identifier[name="${fn}"]`] = function (node) { | ||
if (hasOnlyStringArgument(node)) { | ||
@@ -104,3 +102,6 @@ context.report(node, getSingleStringArgumentMessage(fn)); | ||
if (hasUnitTrue(lastArgument)) { | ||
const lastArgument = getLastArgument(node); | ||
const lastArgumentIsObject = utils.isObjectExpression(lastArgument); | ||
if (lastArgumentIsObject && hasUnitTrue(lastArgument)) { | ||
context.report(lastArgument, getNoUnitTrueMessage(fn)); | ||
@@ -110,3 +111,3 @@ return; | ||
if (hasNeeds(lastArgument)) { | ||
if (lastArgumentIsObject && hasNeeds(lastArgument)) { | ||
context.report(lastArgument, getNoNeedsMessage(fn)); | ||
@@ -116,6 +117,3 @@ return; | ||
if ( | ||
utils.isObjectExpression(lastArgument) && | ||
!hasIntegrationTrue(lastArgument) | ||
) { | ||
if (lastArgumentIsObject && !hasIntegrationTrue(lastArgument)) { | ||
context.report( | ||
@@ -122,0 +120,0 @@ lastArgument, |
@@ -10,2 +10,6 @@ 'use strict'; | ||
function isUnallowedMethod(name) { | ||
return ['set', 'setProperties'].indexOf(name) > -1; | ||
} | ||
module.exports = { | ||
@@ -42,3 +46,3 @@ meta: { | ||
utils.isIdentifier(callee) && | ||
callee.name === 'set' | ||
isUnallowedMethod(callee.name) | ||
) || ( | ||
@@ -48,3 +52,3 @@ utils.isMemberExpression(callee) && | ||
utils.isIdentifier(callee.property) && | ||
callee.property.name === 'set' | ||
isUnallowedMethod(callee.property.name) | ||
); | ||
@@ -51,0 +55,0 @@ |
{ | ||
"name": "eslint-plugin-ember", | ||
"version": "6.0.0", | ||
"version": "6.0.1", | ||
"description": "Eslint plugin for Ember.js apps", | ||
"main": "lib/index.js", | ||
"files": [ | ||
"lib" | ||
], | ||
"directories": { | ||
@@ -54,3 +57,3 @@ "rules": "rules", | ||
"eslint-plugin-import": "^2.14.0", | ||
"jest": "^22.4.3", | ||
"jest": "^23.6.0", | ||
"lerna-changelog": "^0.8.2" | ||
@@ -57,0 +60,0 @@ }, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
0
156174
44
3156