We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Learn more about funding links in repositories.
Report abuse
clean
utils.js
1 parent 77c18d2 commit 61b4b92Copy full SHA for 61b4b92
lib/utils.js
@@ -76,7 +76,7 @@ exports.clean = function (str) {
76
.replace(/^\uFEFF/, '')
77
// (traditional)-> space/name parameters body (lambda)-> parameters body multi-statement/single keep body content
78
.replace(
79
- /^function(?:\s*|\s+[^(]*)\([^)]*\)\s*\{((?:.|\n)*?)\s*\}$|^\([^)]*\)\s*=>\s*(?:\{((?:.|\n)*?)\s*\}|((?:.|\n)*))$/,
+ /^function(?:\s*|\s[^(]*)\([^)]*\)\s*\{((?:.|\n)*?)\}$|^\([^)]*\)\s*=>\s*(?:\{((?:.|\n)*?)\}|((?:.|\n)*))$/,
80
'$1$2$3'
81
);
82
0 commit comments