Original Powershell script