Socket
Socket
Sign inDemoInstall

eslint-plugin-flowtype

Package Overview
Dependencies
Maintainers
1
Versions
185
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-flowtype - npm Package Compare versions

Comparing version 3.6.1 to 3.7.0

8

dist/rules/requireReturnType.js

@@ -20,3 +20,3 @@ 'use strict';

annotateUndefined: {
enum: ['always', 'never'],
enum: ['always', 'never', 'ignore'],
type: 'string'

@@ -45,3 +45,3 @@ },

var annotateReturn = (_lodash2.default.get(context, 'options[0]') || 'always') === 'always';
var annotateUndefined = (_lodash2.default.get(context, 'options[1].annotateUndefined') || 'never') === 'always';
var annotateUndefined = _lodash2.default.get(context, 'options[1].annotateUndefined') || 'never';
var skipArrows = _lodash2.default.get(context, 'options[1].excludeArrowFunctions') || false;

@@ -126,5 +126,5 @@

if (isFunctionReturnUndefined && isReturnTypeAnnotationUndefined && !annotateUndefined) {
if (isFunctionReturnUndefined && isReturnTypeAnnotationUndefined && annotateUndefined === 'never') {
context.report(functionNode, 'Must not annotate undefined return type.');
} else if (isFunctionReturnUndefined && !isReturnTypeAnnotationUndefined && annotateUndefined) {
} else if (isFunctionReturnUndefined && !isReturnTypeAnnotationUndefined && annotateUndefined === 'always') {
context.report(functionNode, 'Must annotate undefined return type.');

@@ -131,0 +131,0 @@ } else if (!isFunctionReturnUndefined && !isReturnTypeAnnotationUndefined && annotateReturn && !returnType && !shouldFilterNode(functionNode)) {

@@ -63,3 +63,3 @@ {

},
"version": "3.6.1"
"version": "3.7.0"
}

Sorry, the diff of this file is too big to display

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