★ wanayoo — archive 1999 https://github.com/nodejs/node/pull/30281Nouvelle recherche | Portail wanayoo
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

url: replace var with let in lib/url.js #30281

Closed
wants to merge 1 commit into from
Closed

Conversation

xefimx
Copy link
Contributor

@xefimx xefimx commented Nov 6, 2019

url: replace var with let and const in lib/url.js

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

trivikr
trivikr approved these changes Nov 6, 2019
let end = -1;
let rest = '';
let lastPos = 0;
let i = 0;
Copy link
Member

@trivikr trivikr Nov 6, 2019

Choose a reason for hiding this comment

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

nit: move i = 0 inside the loop on line 166

Also, add let in a for loop on line 298 and 414?

for (let i = 0; i < rest.length; ++i) {

var hostEnd = -1;
var atSign = -1;
var nonHost = -1;
let hostEnd = -1;
Copy link
Member

@trivikr trivikr Nov 6, 2019

Choose a reason for hiding this comment

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

nit: the variable hostEnd can move inside the loop

@gireeshpunathil
Copy link
Member

@gireeshpunathil gireeshpunathil commented Nov 12, 2019

@trivikr - are your suggestions a blocker from landing? plmk.

@nodejs-github-bot
Copy link
Contributor

@nodejs-github-bot nodejs-github-bot commented Nov 12, 2019

@trivikr
Copy link
Member

@trivikr trivikr commented Nov 12, 2019

@trivikr - are your suggestions a blocker from landing? plmk.

@gireeshpunathil Nope, they're not a blocker.
I've given approval and prefixed nit to my suggestions.

It's optional for @xefimx to follow-up if they want.

Trott added a commit that referenced this issue Nov 17, 2019
PR-URL: #30281
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
@Trott
Copy link
Member

@Trott Trott commented Nov 17, 2019

Landed in 87cef76

@Trott Trott closed this Nov 17, 2019
@Trott
Copy link
Member

@Trott Trott commented Nov 17, 2019

Thanks for the contribution! 🎉

@trivikr trivikr mentioned this pull request Nov 17, 2019
2 tasks
MylesBorins added a commit that referenced this issue Nov 17, 2019
PR-URL: #30281
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
@BridgeAR BridgeAR mentioned this pull request Nov 19, 2019
targos added a commit that referenced this issue Dec 1, 2019
PR-URL: #30281
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
trivikr added a commit to trivikr/node that referenced this issue Dec 7, 2019
@BethGriggs BethGriggs mentioned this pull request Dec 9, 2019
bmeck pushed a commit that referenced this issue Dec 11, 2019
Refs: #30281 (comment)

PR-URL: #30509
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
MylesBorins added a commit that referenced this issue Dec 13, 2019
Refs: #30281 (comment)

PR-URL: #30509
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
MylesBorins added a commit that referenced this issue Dec 17, 2019
PR-URL: #30281
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
@BethGriggs BethGriggs mentioned this pull request Dec 23, 2019
targos added a commit that referenced this issue Jan 14, 2020
Refs: #30281 (comment)

PR-URL: #30509
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
BethGriggs pushed a commit that referenced this issue Feb 6, 2020
Refs: #30281 (comment)

PR-URL: #30509
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

7 participants