Skip to content

Commit

Permalink
tools: favor === over == in license2rtf.js
Browse files Browse the repository at this point in the history
PR-URL: https://github.com/nodejs/node/pull/8068.patch
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: Minwoo Jung <jmwsoft@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: targos - Michaël Zasso <mic.besace@gmail.com>
  • Loading branch information
Trott authored and MylesBorins committed Oct 26, 2016
1 parent f1e14e4 commit bdfa3b3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tools/license2rtf.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ function ParagraphParser() {
if (block_has_c_style_comment) {
var prev = line;
line = line.replace(/^(\s*?)(?:\s?\*\/|\/\*\s|\s\*\s?)/, '$1');
if (prev == line)
if (prev === line)
line = line.replace(/^\s{2}/, '');
if (/\*\//.test(prev))
block_has_c_style_comment = false;
Expand Down Expand Up @@ -142,16 +142,16 @@ function ParagraphParser() {
var line_li = result[2];

// Flush the paragraph when there is a li or an indentation jump
if (line_li || (line_indent != paragraph_line_indent &&
paragraph_line_indent != -1)) {
if (line_li || (line_indent !== paragraph_line_indent &&
paragraph_line_indent !== -1)) {
flushParagraph();
paragraph.li = line_li;
}

// Set the paragraph indent that we use to detect indentation jumps. When
// we just detected a list indicator, wait
// for the next line to arrive before setting this.
if (!line_li && paragraph_line_indent != -1) {
if (!line_li && paragraph_line_indent !== -1) {
paragraph_line_indent = line_indent;
}

Expand Down

0 comments on commit bdfa3b3

Please sign in to comment.