Skip to content

Commit 78b1f9e

Browse files
committed
fix: Remove console.log
1 parent d664007 commit 78b1f9e

File tree

5 files changed

+1629
-1631
lines changed

5 files changed

+1629
-1631
lines changed

lib/inject.js

Lines changed: 11 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,6 @@ function injectRequirements(
2323
injectionRelativePath,
2424
options
2525
) {
26-
console.log('requirementsPath', requirementsPath);
27-
console.log('injectionRelativePath', injectionRelativePath);
28-
console.log('packagePath', packagePath);
2926
const noDeploy = new Set(options.noDeploy || []);
3027

3128
return fse
@@ -34,21 +31,17 @@ function injectRequirements(
3431
.then((zip) =>
3532
BbPromise.resolve(
3633
glob.sync([path.join(requirementsPath, '**')], {
37-
// glob.sync([path.join(packagePath, '..', 'requirements', '**')], {
3834
mark: true,
3935
dot: true,
4036
})
4137
)
42-
.map((file) => {
43-
// console.log('first map file', file);
44-
return [
45-
file,
46-
path.join(
47-
injectionRelativePath,
48-
path.relative(requirementsPath, file)
49-
),
50-
];
51-
})
38+
.map((file) => [
39+
file,
40+
path.join(
41+
injectionRelativePath,
42+
path.relative(requirementsPath, file)
43+
),
44+
])
5245
.filter(
5346
([file, relativeFile]) =>
5447
!file.endsWith('/') &&
@@ -58,13 +51,12 @@ function injectRequirements(
5851
.map(([file, relativeFile]) =>
5952
Promise.all([file, relativeFile, fse.statAsync(file)])
6053
)
61-
.mapSeries(([file, relativeFile, fileStat]) => {
62-
// console.log('file', file);
63-
return zipFile(zip, relativeFile, fse.readFileAsync(file), {
54+
.mapSeries(([file, relativeFile, fileStat]) =>
55+
zipFile(zip, relativeFile, fse.readFileAsync(file), {
6456
unixPermissions: fileStat.mode,
6557
createFolders: false,
66-
});
67-
})
58+
})
59+
)
6860
.then(() => writeZip(zip, packagePath))
6961
);
7062
}

package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@
7777
"sha256-file": "1.0.0",
7878
"shell-quote": "^1.8.1"
7979
},
80+
"peerDependencies": {
81+
"serverless": ">=2.32"
82+
},
8083
"lint-staged": {
8184
"*.js": [
8285
"eslint"

0 commit comments

Comments
 (0)