From 563d5bf9769a79bb03d998defb6bded79f8935a6 Mon Sep 17 00:00:00 2001 From: Nicolas Giraud Date: Tue, 15 Feb 2022 14:11:01 +0100 Subject: [PATCH] Fix #37 --- src/PhpAssumptions/Cli.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/PhpAssumptions/Cli.php b/src/PhpAssumptions/Cli.php index 6d5155b..f40f662 100644 --- a/src/PhpAssumptions/Cli.php +++ b/src/PhpAssumptions/Cli.php @@ -102,7 +102,7 @@ public function handle(array $args) break; } - $excludes = $this->getPathsFromList($this->cli->arguments->get('exclude')); + $excludes = $this->getPathsFromList((string) $this->cli->arguments->get('exclude')); $nodeTraverser = new NodeTraverser(); @@ -135,7 +135,7 @@ public function handle(array $args) private function getPathsFromList($list) { $paths = []; - if (strlen($list) > 0) { + if ($list !== '') { $items = explode(',', $list); foreach ($items as $item) { $paths = array_merge($paths, $this->getPaths($item));