Toolcache: fix typos in windows toolcache provisioners

This commit is contained in:
Maksim Petrov
2019-12-30 14:51:09 +03:00
parent 6aa21f425e
commit d1ed5029b5
2 changed files with 4 additions and 5 deletions

View File

@@ -37,14 +37,14 @@ function ToolcacheTest {
if (Test-Path "$env:AGENT_TOOLSDIRECTORY\$SoftwareName")
{
$description = ""
[array]$instaledVersions = GetChildFolders -Path "$env:AGENT_TOOLSDIRECTORY\$SoftwareName"
if ($instaledVersions.count -gt 0){
[array]$installedVersions = GetChildFolders -Path "$env:AGENT_TOOLSDIRECTORY\$SoftwareName"
if ($installedVersions.count -gt 0){
$softwarePackages = $packages | Where-Object { $_.ToolName -eq $SoftwareName }
foreach($softwarePackage in $softwarePackages)
{
foreach ($version in $softwarePackage.Versions)
{
$foundVersion = $instaledVersions | where { $_.StartsWith($version) }
$foundVersion = $installedVersions | where { $_.StartsWith($version) }
if ($foundVersion -ne $null){