Skip to content

Commit 882184e

Browse files
committed
fix: file has to be non empty array
1 parent 717c2ab commit 882184e

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

src/cli.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,9 @@ const defaultAction = {
9292
// Program action
9393
const programAction = {};
9494
['detached', 'exec', 'file', 'index', 'privileged', 'service', 'user'].forEach(key => {
95-
if (program[key] !== undefined) {
96-
programAction[key] = program[key];
95+
const value = program[key];
96+
if (value !== undefined && (key !== 'file' || value.length > 0)) {
97+
programAction[key] = value;
9798
}
9899
});
99100

0 commit comments

Comments
 (0)