Skip to content

Commit

Permalink
(chocolatey#2867) Fix wording/spelling of the added comment
Browse files Browse the repository at this point in the history
Just tweaking the added comment here to make a little more sense and fix
a typo.
  • Loading branch information
vexx32 committed May 3, 2023
1 parent f966315 commit 8592eb4
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -448,9 +448,10 @@ private static void SetGlobalOptions(IList<string> args, ChocolateyConfiguration
{
if (!string.IsNullOrWhiteSpace(config.CommandName))
{
// The setOptions lambda above is called twice, once to set the command name, and then to execute the command with all options.
// To ensure correct option of the help options, we need to reset them to false in the first execution, to then have them parsed correctly in the second
// iteration.
// This method is called twice each run, once when setting the command name and global options (here), and then to set all the
// command-specific options and actually execute the command.
// To ensure correct operation, we need to reset the help options to false in the first execution, to then have them
// parsed correctly in the second iteration.
config.HelpRequested = false;
config.ShowOnlineHelp = false;
config.UnsuccessfulParsing = false;
Expand Down

0 comments on commit 8592eb4

Please # to comment.