File tree Expand file tree Collapse file tree
src/modules/launcher/Plugins/Microsoft.Plugin.Shell Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -156,8 +156,8 @@ private List<Result> ResultsFromlHistory()
156156
157157 private ProcessStartInfo PrepareProcessStartInfo ( string command , bool runAsAdministrator = false )
158158 {
159- command = command . Trim ( ) ;
160- command = Environment . ExpandEnvironmentVariables ( command ) ;
159+ string trimmedCommand = command . Trim ( ) ;
160+ command = Environment . ExpandEnvironmentVariables ( trimmedCommand ) ;
161161 var workingDirectory = Environment . GetFolderPath ( Environment . SpecialFolder . UserProfile ) ;
162162 var runAsAdministratorArg = ! runAsAdministrator && ! _settings . RunAsAdministrator ? string . Empty : "runas" ;
163163
@@ -218,7 +218,7 @@ private ProcessStartInfo PrepareProcessStartInfo(string command, bool runAsAdmin
218218
219219 info . UseShellExecute = true ;
220220
221- _settings . AddCmdHistory ( command ) ;
221+ _settings . AddCmdHistory ( trimmedCommand ) ;
222222
223223 return info ;
224224 }
You can’t perform that action at this time.
0 commit comments