diff --git a/profiles/DerGeret/Windows/Setup.ps1 b/profiles/DerGeret/Windows/Setup.ps1 index bb1388ed..78724bee 100644 --- a/profiles/DerGeret/Windows/Setup.ps1 +++ b/profiles/DerGeret/Windows/Setup.ps1 @@ -14,7 +14,7 @@ $Global:SetupConfigPostprocessor = { $newIndex = [int]$installationPartition.InnerText; $installationPartition.InnerText = "$($newIndex + 1)"; $partitionCreations = $diskConfig.SelectSingleNode("./ua:CreatePartitions", $namespace); - $newPartition = $partitionCreations.FirstChild.CloneNode($true); + $newPartition = $partitionCreations.SelectNodes("./ua:CreatePartition", $namespace)[0].CloneNode($true); $newPartition.SelectSingleNode("./ua:Order", $namespace).InnerText = "$newIndex"; $newPartition.SelectSingleNode("./ua:Size", $namespace).InnerText = "65536"; # For testing purposes @@ -30,7 +30,7 @@ $Global:SetupConfigPostprocessor = { $partitionCreations.AppendChild($newPartition); $partitionModifications = $diskConfig.SelectSingleNode("./ua:ModifyPartitions", $namespace); - $newModification = $diskConfig.ChildNodes[2].CloneNode($true); + $newModification = $diskConfig.SelectNodes("./ua:ModifyPartition", $namespace)[2].CloneNode($true); $newModification.SelectSingleNode("./ua:Order", $namespace).InnerText = "$newIndex"; $newModification.SelectSingleNode("./ua:PartitionID", $namespace).InnerText = "$newIndex";