Skip to content

Commit

Permalink
Remove comment
Browse files Browse the repository at this point in the history
  • Loading branch information
fippli committed Apr 17, 2020
1 parent bc51ce4 commit 69bb271
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
// Function that times the execution of another funciton
// Usage timeIt(foo, "Description of execution")(arg1, arg2, ...)

const timeIt = (func, description) => async (...args) => {
console.time(description);
try {
return await func(...args); // Wait for the result here
return await func(...args);
} catch (error) {
throw error;
} finally {
Expand Down

0 comments on commit 69bb271

Please sign in to comment.