Changing name of parser attribute.

This commit is contained in:
mark_story 2010-10-10 00:40:34 -04:00
parent f1ee46749b
commit c0d15a420c

View file

@ -37,6 +37,13 @@ class Shell extends Object {
*/
public $Dispatch = null;
/**
* An instance of ConsoleOptionParser that has been configured for this class.
*
* @var ConsoleOptionParser
*/
public $OptionParser;
/**
* If true, the script will ask for permission to perform actions.
*
@ -345,10 +352,10 @@ class Shell extends Object {
return $this->{$command}->runCommand('execute', $argv);
}
$this->parser = $this->_getOptionParser();
list($this->params, $this->args) = $this->parser->parse($argv);
$this->OptionParser = $this->_getOptionParser();
list($this->params, $this->args) = $this->OptionParser->parse($argv);
if (isset($this->params['help'])) {
return $this->out($this->parser->help());
return $this->out($this->OptionParser->help());
}
if ($isMethod) {