Fix for history

This commit is contained in:
George Fleming
2015-11-05 09:30:09 -08:00
committed by Andrew Schwartzmeyer
parent 7a77539b50
commit aeabd5aa53
+4 -2
View File
@@ -250,13 +250,15 @@ namespace Microsoft.Samples.PowerShell.Host
// If there is any input pass it in, otherwise just invoke the
// the pipeline.
PSInvocationSettings settings = new PSInvocationSettings();
settings.AddToHistory = true;
if (input != null)
{
this.currentPowerShell.Invoke(new object[] { input });
this.currentPowerShell.Invoke(new object[] { input }, settings);
}
else
{
this.currentPowerShell.Invoke();
this.currentPowerShell.Invoke(null, settings);
}
}
finally