From 68d1f4e74a180b95f4549c9d2331d07f2f231d65 Mon Sep 17 00:00:00 2001 From: john Date: Mon, 23 Jul 2018 14:55:46 -0700 Subject: [PATCH] Add a simple fix to detect aws-sdk Fixes #3 --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 28b6e47..e60677f 100644 --- a/index.js +++ b/index.js @@ -10,7 +10,7 @@ function getHandlerFilePath(servicePath, handler) { function resolveToBaseModuleGlob(file) { const relative = path.relative(process.cwd(), file); const match = relative.match(/^((\.\.\/)*node_modules\/\S+?\/)/); - if (match) { + if (match && !match[1].endsWith('aws-sdk')) { return `${match[1]}**`; } return relative;