Skip to content

Commit ebba278

Browse files
committedApr 9, 2024
chore(golang): fix "dtoName is not defined" error
Correction for 056ecce commit.
1 parent 6d15337 commit ebba278

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎src/templates/routes.go.ejs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,8 @@ endpoints.forEach(function(endpoint) {
195195
// LATER: do we really need signature and cache?
196196
const dataType = obtainDtoName(dto)
197197
const resultVariableDeclaration = hasGetMany
198-
? `result := []${dtoName}\{\}`
199-
: `var result ${dtoName}`
198+
? `result := []${dataType}\{\}`
199+
: `var result ${dataType}`
200200
201201
const queryFunction = hasGetOne ? 'Get' : 'Select'
202202
// LATER: handle only particular method (get/post/put)

0 commit comments

Comments
 (0)