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: replace string concatenation with template · nodejs/node@afbdd01

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • lib
    • fs.js
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎lib/fs.js‎

Copy file name to clipboardExpand all lines: lib/fs.js
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ function rethrow() {
115115
var backtrace = new Error();
116116
return function(err) {
117117
if (err) {
118-
backtrace.stack = err.name + ': ' + err.message +
118+
backtrace.stack = `${err.name}: ${err.message}` +
119119
backtrace.stack.substr(backtrace.name.length);
120120
throw backtrace;
121121
}
@@ -1894,7 +1894,7 @@ fs.mkdtemp = function(prefix, options, callback) {
18941894
var req = new FSReqWrap();
18951895
req.oncomplete = callback;
18961896

1897-
binding.mkdtemp(prefix + 'XXXXXX', options.encoding, req);
1897+
binding.mkdtemp(`${prefix}XXXXXX`, options.encoding, req);
18981898
};
18991899

19001900

@@ -1907,7 +1907,7 @@ fs.mkdtempSync = function(prefix, options) {
19071907
}
19081908
options = getOptions(options, {});
19091909
nullCheck(prefix);
1910-
return binding.mkdtemp(prefix + 'XXXXXX', options.encoding);
1910+
return binding.mkdtemp(`${prefix}XXXXXX`, options.encoding);
19111911
};
19121912

19131913

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.