From b13e01af18fb5cd378ee9258f21d8148b001a569 Mon Sep 17 00:00:00 2001 From: "John S. Dvorak" Date: Fri, 27 Apr 2018 10:52:04 -0700 Subject: [PATCH] Remove path annotation This brings bixby-express into alignment with the pr at https://github.com/bixbyjs/bixby/pull/1 --- app/service.js | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/app/service.js b/app/service.js index 1d09d77..1d8c295 100644 --- a/app/service.js +++ b/app/service.js @@ -11,19 +11,15 @@ exports = module.exports = function(IoC, logger) { return Promise.all(components.map(function(comp) { return comp.create(); } )) .then(function(srvs) { srvs.forEach(function(srv, i) { - var component = components[i] - , path = component.a['@path']; + var component = components[i]; // TODO: Improve how the path is determined, if it is not annotated // ie, package namespace, etc // only prefix path if more than one service is present, otherwise use root - logger.info('Loaded HTTP service: ' + path); - if (path) { - service.use(path, srv); - } else { - service.use(srv); - } + logger.info('Loaded HTTP service: ' + component.a['@implements']); + service.use(srv); + }); }) .then(function() {