Remove non-existent variable

This commit is contained in:
Manuel Thalmann 2023-07-25 12:40:35 +02:00
parent 5b9f22eec2
commit 0609221a8e

View file

@ -285,22 +285,24 @@ class Context {
$(
for ($i = 0; $i -lt $oldContent.Count; $i++) {
if ($_ -eq "[Accounts]") {
$line = $oldContent[$i];
if ($line -eq "[Accounts]") {
$accountSectionEntered = $true;
}
if (
($_ -eq "" -and $accountSectionEntered) -or
($line -eq "" -and $accountSectionEntered) -or
(
(-not $accountSectionLeft) -and
($_ -ne "") -and
($line -ne "") -and
($i -eq ($oldContent.Count - 1))
)) {
$accountSectionLeft = $true;
$newSettings;
}
$_;
$line;
}) | Set-Content ($this.GetNextcloudConfigFile());
Write-Information "New nextcloud config:";