Skip to content

Commit

Permalink
test: replace string concatenation with template
Browse files Browse the repository at this point in the history
Replace string concatenation with template literals in
test/async-hooks/verify-graph.js.

PR-URL: #14279
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
  • Loading branch information
miccycn authored and addaleax committed Jul 18, 2017
1 parent 85c181a commit 337a865
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/async-hooks/verify-graph.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ module.exports.printGraph = function printGraph(hooks) {
function procesNode(x) {
const key = x.type.replace(/WRAP/, '').toLowerCase();
if (!ids[key]) ids[key] = 1;
const id = key + ':' + ids[key]++;
const id = `${key}:${ids[key]++}`;
uidtoid[x.uid] = id;
const triggerAsyncId = uidtoid[x.triggerAsyncId] || null;
graph.push({ type: x.type, id, triggerAsyncId });
Expand Down

0 comments on commit 337a865

Please sign in to comment.