GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — lib: remove deprecated string methods · nodejs/node@fa220ca

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • lib
    • _http_agent.js
    • internal/main
      • print_help.js
    • repl.js
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎lib/_http_agent.js‎

Copy file name to clipboardExpand all lines: lib/_http_agent.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ const {
3838
StringPrototypeIndexOf,
3939
StringPrototypeSplit,
4040
StringPrototypeStartsWith,
41-
StringPrototypeSubstr,
41+
StringPrototypeSubstring,
4242
Symbol,
4343
} = primordials;
4444

@@ -363,7 +363,7 @@ function calculateServerName(options, req) {
363363
// Leading '[', but no ']'. Need to do something...
364364
servername = hostHeader;
365365
} else {
366-
servername = StringPrototypeSubstr(hostHeader, 1, index - 1);
366+
servername = StringPrototypeSubstring(hostHeader, 1, index);
367367
}
368368
} else {
369369
servername = StringPrototypeSplit(hostHeader, ':', 1)[0];
Collapse file

‎lib/internal/main/print_help.js‎

Copy file name to clipboardExpand all lines: lib/internal/main/print_help.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const {
1111
RegExpPrototypeSymbolReplace,
1212
StringPrototypeLocaleCompare,
1313
StringPrototypeSlice,
14-
StringPrototypeTrimLeft,
14+
StringPrototypeTrimStart,
1515
StringPrototypeRepeat,
1616
SafeMap,
1717
} = primordials;
@@ -180,7 +180,7 @@ function format(
180180
else
181181
text += StringPrototypeRepeat(' ', firstColumn - displayName.length);
182182

183-
text += StringPrototypeTrimLeft(
183+
text += StringPrototypeTrimStart(
184184
indent(fold(displayHelpText, secondColumn), firstColumn)) + '\n';
185185
}
186186

Collapse file

‎lib/repl.js‎

Copy file name to clipboardExpand all lines: lib/repl.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ const {
9090
StringPrototypeSplit,
9191
StringPrototypeStartsWith,
9292
StringPrototypeTrim,
93-
StringPrototypeTrimLeft,
93+
StringPrototypeTrimStart,
9494
StringPrototypeToLocaleLowerCase,
9595
Symbol,
9696
SyntaxError,
@@ -1326,7 +1326,7 @@ function complete(line, callback) {
13261326
let completeOn, group;
13271327

13281328
// Ignore right whitespace. It could change the outcome.
1329-
line = StringPrototypeTrimLeft(line);
1329+
line = StringPrototypeTrimStart(line);
13301330

13311331
let filter = '';
13321332

0 commit comments

Comments
0 (0)
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.