Skip to content

Commit

Permalink
fix(controller): fixes wrong mapping
Browse files Browse the repository at this point in the history
  • Loading branch information
matzehecht committed Aug 21, 2020
1 parent f5f0cc0 commit 8061be7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ export class KoaOasRouter<StateT = any, CustomT = {}> extends Router {

// Import the controller belonging to it
importPromises.push(
import(path.resolve(path.join(controllerBasePath, controllerName === 'index' ? controllerName.toPascalCase() : 'index')))
import(path.resolve(path.join(controllerBasePath, controllerName !== 'index' ? controllerName.toPascalCase() : 'index')))
.then((controller) => {
// For each operation (with operationId)
Object.entries(operationMapping).forEach(([operationId, operation]) => {
Expand Down

0 comments on commit 8061be7

Please sign in to comment.