Bug 1665164: remove unused get_command logic from CommandAction r=firefox-build-system-reviewers,rstewart

In the patch for bug 1656993, the case in which
get_command was being set was removed.
Accordingly, its usage in CommandAction will always be evaluated to
`False`, and it can be deleted.

Differential Revision: https://phabricator.services.mozilla.com/D90198
This commit is contained in:
Mitchell Hentges 2020-09-15 18:56:03 +00:00
parent 82a405b520
commit b1c1e629c0

View File

@ -137,12 +137,6 @@ class CommandAction(argparse.Action):
# Try to find similar commands, may raise UnknownCommandError.
command = self._suggest_command(command)
# This is used by the `mach` driver to find the command name amidst
# global arguments.
if getattr(self._context, 'get_command', False) is True:
setattr(namespace, 'command', command)
return
handler = self._mach_registrar.command_handlers.get(command)
prog = command