Skip to content

Commit 090d0d1

Browse files
committed
fix: correctly join a multi-line query when the 2nd line doesn't start with a leading space
1 parent 822cf93 commit 090d0d1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/cli.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ const createEndpoints = async (destDir, fileName, config) => {
5656

5757
// "SELECT *\n FROM foo" => "'SELECT * FROM foo'"
5858
"formatQuery": (query) => {
59-
return "'" + query.replace(/\n[ ]+/g, ' ') + "'";
59+
return "'" + query.replace(/\n[ ]*/g, ' ') + "'";
6060
}
6161
}
6262
);

0 commit comments

Comments
 (0)