Skip to content

Commit

Permalink
chocolatey-visualstudio.extension: fix LTSC updates
Browse files Browse the repository at this point in the history
  • Loading branch information
DMaxter committed Oct 13, 2022
1 parent 5be2377 commit d9b27b8
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@ Install-ChocolateyPackage
if ($VisualStudioYear -ne '')
{
$channelReference = Get-VSChannelReference -VisualStudioYear $VisualStudioYear -Preview $Preview

$installed = Get-VisualStudioInstance | Where-Object { $_.ChannelId -like ($channelReference.ChannelId+ "*")}
if ($null -ne $installed) {
$channelReference.ChannelId = $installed.ChannelId
}

if ($Product -ne '')
{
$productReference = Get-VSProductReference -ChannelReference $channelReference -Product $Product
Expand Down

0 comments on commit d9b27b8

Please sign in to comment.