Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

eslint-plugin-lodash

Package Overview
Dependencies
Maintainers
3
Versions
100
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-lodash - npm Package Compare versions

Comparing version 1.8.2 to 1.8.3

9

CHANGELOG.md

@@ -11,4 +11,11 @@ # Change Log

[unreleased]: https://github.com/wix/eslint-plugin-lodash/compare/v1.8.2...HEAD
[unreleased]: https://github.com/wix/eslint-plugin-lodash/compare/v1.8.3...HEAD
## [1.8.3] - 2016-05-01
### Fixed
- Fixed case where `collection-return` reports false positive in nested arrow functions. ([`e59f507`][e59f507])
[e59f507]: https://github.com/wix/eslint-plugin-lodash/commit/e59f50754bf9fa9463d98db9f0861fefbd3d2144
[1.8.3]: https://github.com/wix/eslint-plugin-lodash/compare/v1.8.3...v1.8.2
## [1.8.2] - 2016-04-28

@@ -15,0 +22,0 @@ ### Fixed

17

lib/rules/collection-return.js

@@ -28,4 +28,4 @@ /**

function addToCallStackIfCollectionMethod(node) {
if (lodashUtil.isLodashCollectionMethod(node.parent, settings.version) && (lodashUtil.isLodashCall(node.parent, settings.pragma) || lodashUtil.isLodashWrapper(node.parent, settings.pragma, settings.version))) {
callStack.push({ node: node.parent });
if (lodashUtil.isLodashCollectionMethod(node, settings.version) && (lodashUtil.isLodashCall(node, settings.pragma) || lodashUtil.isLodashWrapper(node, settings.pragma, settings.version))) {
callStack.push({ node: node });
}

@@ -36,3 +36,3 @@ }

FunctionExpression: function FunctionExpression(node) {
addToCallStackIfCollectionMethod(node);
addToCallStackIfCollectionMethod(node.parent);
callStack.push({ node: node, found: false });

@@ -43,4 +43,4 @@ },

ArrowFunctionExpression: function ArrowFunctionExpression(node) {
addToCallStackIfCollectionMethod(node);
if (node.body.type === 'BlockStatement') {
addToCallStackIfCollectionMethod(node.parent);
callStack.push({ node: node, found: false });

@@ -50,4 +50,3 @@ }

'ArrowFunctionExpression:exit': function ArrowFunctionExpressionExit(node) {
var last = _.last(callStack);
if (last && last.node === node) {
if (node.body.type === 'BlockStatement') {
handleExitOfFunctionWithBlock(node);

@@ -61,10 +60,4 @@ }

}
},
'CallExpression:exit': function CallExpressionExit(node) {
var last = _.last(callStack);
if (last && last.node === node) {
callStack.pop();
}
}
};
};
{
"name": "eslint-plugin-lodash",
"version": "1.8.2",
"version": "1.8.3",
"author": "Omer Ganim <ganimomer@gmail.com>",

@@ -5,0 +5,0 @@ "description": "Lodash specific linting rules for ESLint",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc