FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fs: simplify realpathSync by himself65 · Pull Request #35413 · nodejs/node · GitHub

/ node Public

fs: simplify realpathSync - #35413

Closed
himself65 wants to merge 2 commits into
nodejs:masterfrom
himself65:20200929-simplify
Closed

fs: simplify realpathSync#35413
himself65 wants to merge 2 commits into
nodejs:masterfrom
himself65:20200929-simplify

Conversation

Copy link
Copy Markdown
Member
Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • commit message follows commit guidelines

nodejs-github-bot added the fs Issues and PRs related to the fs subsystem / file system. label Sep 29, 2020

Copy link
Copy Markdown
Member Author

note that getOptions will returns defaultOptions if options is nil

function getOptions(options, defaultOptions) {
if (options === null || options === undefined ||
typeof options === 'function') {
return defaultOptions;
}

bnoordhuis left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

There's another simplification you can make on line 1633:

  if (isWindows && !knownHard[base]) {

!knownHard[base] is always true because knownHard is still an empty object at that point.

Copy link
Copy Markdown
Member Author
if (isWindows && !knownHard[base]) {

I see, thanks a lot

himself65 added the request-ci Add this label to start a Jenkins CI on a PR. label Sep 29, 2020
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Sep 29, 2020

Copy link
Copy Markdown
Collaborator

lpinca pushed a commit that referenced this pull request Oct 4, 2020
PR-URL: #35413
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>

lpinca commented Oct 4, 2020

Copy link
Copy Markdown
Member

Landed in b8f34b2.

lpinca closed this Oct 4, 2020
danielleadams pushed a commit that referenced this pull request Oct 6, 2020
PR-URL: #35413
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
danielleadams mentioned this pull request Oct 6, 2020
MylesBorins pushed a commit that referenced this pull request Nov 3, 2020
PR-URL: #35413
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
MylesBorins mentioned this pull request Nov 3, 2020
MylesBorins pushed a commit that referenced this pull request Nov 16, 2020
PR-URL: #35413
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
joesepi pushed a commit to joesepi/node that referenced this pull request Jan 8, 2021
PR-URL: nodejs#35413
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fs Issues and PRs related to the fs subsystem / file system.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants


Back | FazBrowse Home | New Git URL