From efdf2af7487138b3385c3022227ae54b1291e311 Mon Sep 17 00:00:00 2001 From: Sn0wCrack <442287+Sn0wCrack@users.noreply.github.com> Date: Fri, 1 May 2026 15:35:43 +1000 Subject: [PATCH] fix: cast port to string before adding to options This function is hinted as a `string[]` but `Host::getPort()` can return an int or string. This causes issues in the `rsync_rsh` function has it passes the values of the array to functions that require a string to be used. --- src/Host/Host.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Host/Host.php b/src/Host/Host.php index f4a476ea4..6055b5396 100644 --- a/src/Host/Host.php +++ b/src/Host/Host.php @@ -278,7 +278,7 @@ public function connectionOptions(): array } } if ($this->has('port')) { - $options = array_merge($options, ['-p', $this->getPort()]); + $options = array_merge($options, ['-p', (string) $this->getPort()]); } if ($this->has('config_file')) { $options = array_merge($options, ['-F', parse_home_dir($this->getConfigFile())]);