From e445d734739962cb1509c5a3b3483d293a1add88 Mon Sep 17 00:00:00 2001 From: Iristyle Date: Wed, 15 May 2013 07:38:25 -0400 Subject: [PATCH] fix: SublimeHelpers Get-* returns too much data - on first directory create, function outputs would include two values instead of just the path string, which confused callers and generated errors during first time package installs --- core/SublimeHelpers.ps1 | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/core/SublimeHelpers.ps1 b/core/SublimeHelpers.ps1 index bcfa23a..6c40b39 100644 --- a/core/SublimeHelpers.ps1 +++ b/core/SublimeHelpers.ps1 @@ -12,7 +12,10 @@ function Get-SublimeSettingsPath function Get-SublimePackagesPath { $packagesPath = Join-Path (Get-SublimeSettingsPath) 'Packages' - if (!(Test-Path $packagesPath)) { New-Item $packagesPath -Type Directory } + if (!(Test-Path $packagesPath)) + { + New-Item $packagesPath -Type Directory | Out-Null + } return $packagesPath } @@ -20,7 +23,10 @@ function Get-SublimePackagesPath function Get-SublimeUserPath { $path = Join-Path (Get-SublimePackagesPath) 'User' - if (!(Test-Path $path)) { New-Item $path -Type Directory } + if (!(Test-Path $path)) + { + New-Item $path -Type Directory | Out-Null + } return $path }