@@ -47,12 +47,12 @@ function extractInsertValues(queryAst) {
47
47
// ]
48
48
// } => [ 'user_id' ]
49
49
function extractUpdateValues (queryAst ) {
50
- // TODO : distinguish between b.param and q.param and extract only first
50
+ // LATER : distinguish between b.param and q.param and extract only first
51
51
return queryAst .set .map (elem => elem .value .type === ' param' ? elem .value .value : null )
52
52
.filter (value => value) // filter out nulls
53
53
}
54
54
55
- // TODO : consider taking into account b.params from WHERE clause
55
+ // LATER : consider taking into account b.params from WHERE clause
56
56
function extractProperties (queryAst ) {
57
57
if (queryAst .type === ' select' ) {
58
58
return extractSelectParameters (queryAst);
@@ -109,7 +109,7 @@ function query2dto(parser, method) {
109
109
" maxFieldNameLength" : lengthOfLongestString (props .map (el => el .indexOf (' _' ) < 0 ? el : el .replace (/ _/ g , ' ' ))),
110
110
// required for de-duplication
111
111
// [ {name:foo, type:int}, {name:bar, type:string} ] => "foo=int bar=string"
112
- // TODO : sort before join
112
+ // LATER : sort before join
113
113
" signature" : propsWithTypes .map (field => ` ${ field .name } =${ field .type } ` ).join (' ' )
114
114
};
115
115
}
@@ -171,14 +171,14 @@ endpoints.forEach(function(endpoint) {
171
171
const hasGetMany = method .name === ' get_list' ;
172
172
if (hasGetOne || hasGetMany) {
173
173
const dto = query2dto (sqlParser, method);
174
- // TODO : do we really need signature and cache?
174
+ // LATER : do we really need signature and cache?
175
175
const cacheKey = dto ? dto .signature : null ;
176
176
const dtoName = dtoInCache (dto) ? dtoCache[cacheKey] : dto .name ;
177
177
const dataType = hasGetMany ? ' []' + dtoName : dtoName;
178
178
179
179
const queryFunction = hasGetOne ? ' Get' : ' Select' ;
180
- // TODO : handle only particular method (get/post/put)
181
- // TODO : include method/path into an error message
180
+ // LATER : handle only particular method (get/post/put)
181
+ // LATER : include method/path into an error message
182
182
% >
183
183
r .Get (" <%- path %>" , func (w http .ResponseWriter , r * http .Request ) {
184
184
< %
@@ -215,7 +215,7 @@ endpoints.forEach(function(endpoint) {
215
215
}
216
216
if (method .name === ' post' ) {
217
217
const dto = query2dto (sqlParser, method);
218
- // TODO : do we really need signature and cache?
218
+ // LATER : do we really need signature and cache?
219
219
const cacheKey = dto ? dto .signature : null ;
220
220
const dataType = dtoInCache (dto) ? dtoCache[cacheKey] : dto .name ;
221
221
% >
@@ -242,7 +242,7 @@ endpoints.forEach(function(endpoint) {
242
242
}
243
243
if (method .name === ' put' ) {
244
244
const dto = query2dto (sqlParser, method);
245
- // TODO : do we really need signature and cache?
245
+ // LATER : do we really need signature and cache?
246
246
const cacheKey = dto ? dto .signature : null ;
247
247
const dataType = dtoInCache (dto) ? dtoCache[cacheKey] : dto .name ;
248
248
% >
0 commit comments