Skip to content

tools: enable no-else-return ESLint rule

Rodrigo Muino Tomonari requested to merge github/fork/Trott/no-else-return into master

If an if block contains a return statement, the else block becomes unnecessary. Its contents can be placed outside of the block.

Refs: http://eslint.org/docs/rules/no-else-return

Inspired by https://github.com/nodejs/node/pull/11148

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

tools test lib benchmark

Merge request reports

Loading