Skip to content

Commit 5cc5df1

Browse files
committed
Merge pull request #28 from zyoung51/fix/add-break
Stop search when first controller is found
2 parents ab81bc4 + c286b07 commit 5cc5df1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

fittings/swagger_router.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ module.exports = function create(fittingDef, bagpipes) {
4848
controller = require(controllerPath);
4949
controllerFunctionsCache[controllerName] = controller;
5050
debug('controller found', controllerPath);
51+
break;
5152
} catch (err) {
5253
if (!mockMode && i === controllersDirs.length - 1) {
5354
return cb(err);

0 commit comments

Comments
 (0)