Skip to content

Commit 34797ba

Browse files
committed
refactor: Adapt pip to modern logs
1 parent 0eb1483 commit 34797ba

File tree

4 files changed

+341
-258
lines changed

4 files changed

+341
-258
lines changed

index.js

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,13 @@ class ServerlessPythonRequirements {
7474
(options.dockerSsh || options.dockerImage || options.dockerFile)
7575
) {
7676
if (!this.warningLogged) {
77-
this.serverless.cli.log(
78-
'WARNING: You provided a docker related option but dockerizePip is set to false.'
79-
);
77+
if (this.log) {
78+
this.log.warning('You provided a docker related option but dockerizePip is set to false.');
79+
} else {
80+
this.serverless.cli.log(
81+
'WARNING: You provided a docker related option but dockerizePip is set to false.'
82+
);
83+
}
8084
this.warningLogged = true;
8185
}
8286
}

0 commit comments

Comments
 (0)