From a2cc18a43454e56858aa193f1edf1c1afb7bb09f Mon Sep 17 00:00:00 2001 From: Anthony Axenov Date: Sat, 9 Nov 2024 19:05:37 +0800 Subject: [PATCH] Misc --- src/ArgumentParser.php | 2 +- src/Converters/Abstract/AbstractConverter.php | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/ArgumentParser.php b/src/ArgumentParser.php index b79e11c..2574adf 100644 --- a/src/ArgumentParser.php +++ b/src/ArgumentParser.php @@ -18,7 +18,7 @@ class ArgumentParser /** * @var array Parsed and ready to use */ - protected array $parsed; + protected array $parsed = []; /** * Constructor diff --git a/src/Converters/Abstract/AbstractConverter.php b/src/Converters/Abstract/AbstractConverter.php index 74018f7..8817b76 100644 --- a/src/Converters/Abstract/AbstractConverter.php +++ b/src/Converters/Abstract/AbstractConverter.php @@ -62,7 +62,8 @@ abstract class AbstractConverter $this->setCollectionVars(); foreach ($collection->iterate() as $path => $item) { // $this->requests[$path][] = $this->makeRequest($item); - $this->writeRequest($this->makeRequest($item), $path); + $request = $this->makeRequest($item); + $this->writeRequest($request, $path); } return $this; } @@ -103,6 +104,7 @@ abstract class AbstractConverter foreach ($this->collection?->variable ?? [] as $var) { Environment::instance()->setCustomVar($var->key, $var->value); } + return $this; }