Skip to content

Commit 08cb820

Browse files
committed
chore: improve comments
1 parent 2e588ff commit 08cb820

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/cli.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ const createEndpoints = async (destDir, lang, config) => {
161161
{
162162
"endpoints": config,
163163

164-
// "... WHERE id = :p.id" => [ "p.id" ] => [ "p.id" ]
164+
// "... WHERE id = :p.id" => [ "p.id" ]
165165
"extractParams": (query) => query.match(/(?<=:)[pb]\.\w+/g) || [],
166166

167167
// [ "p.page", "b.num" ] => '"page": req.params.page, "num": req.body.num'
@@ -181,7 +181,7 @@ const createEndpoints = async (destDir, lang, config) => {
181181
).join(', ');
182182
},
183183

184-
// "SELECT *\n FROM foo" => "SELECT * FROM foo"
184+
// "SELECT *\n FROM foo WHERE id = :p.id" => "SELECT * FROM foo WHERE id = :id"
185185
"formatQuery": (query) => {
186186
return removePlaceholders(flattenQuery(query));
187187
},

0 commit comments

Comments
 (0)