Skip to content

Commit

Permalink
Fixed Psalm PossiblyInvalidOperand (#27)
Browse files Browse the repository at this point in the history
  • Loading branch information
SmetDenis authored Aug 3, 2023
1 parent 535fc4f commit 718c1df
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Ini.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ protected function render(array $data = [], array $parent = []): string
$result[] = $this->render($dataValue, $sections);
} else {
foreach ($dataValue as $key => $value) {
$result[] = $dataKey . '[' . $key . '] = "' . \str_replace('"', '\"', $value) . '"';
$result[] = $dataKey . '[' . $key . '] = "' . \str_replace('"', '\"', (string)$value) . '"';
}
}
} else {
$result[] = $dataKey . ' = "' . \str_replace('"', '\"', $dataValue) . '"';
$result[] = $dataKey . ' = "' . \str_replace('"', '\"', (string)$dataValue) . '"';
}
}

Expand Down

0 comments on commit 718c1df

Please sign in to comment.