diff options
author | John L. Villalovos <john@sodarock.com> | 2022-06-03 20:33:04 -0700 |
---|---|---|
committer | John L. Villalovos <john@sodarock.com> | 2022-06-03 20:33:04 -0700 |
commit | 6189437d2c8d18f6c7d72aa7743abd6d36fb4efa (patch) | |
tree | 83bb1a31163548f24f0e87c66f7edfa5a6a8a226 /gitlab/v4/cli.py | |
parent | 00aec96ed0b60720362c6642b416567ff39aef09 (diff) | |
download | gitlab-6189437d2c8d18f6c7d72aa7743abd6d36fb4efa.tar.gz |
chore: rename `__call__()` to `run()` in GitlabCLI
Less confusing to have it be a normal method.
Diffstat (limited to 'gitlab/v4/cli.py')
-rw-r--r-- | gitlab/v4/cli.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gitlab/v4/cli.py b/gitlab/v4/cli.py index b396e46..226459e 100644 --- a/gitlab/v4/cli.py +++ b/gitlab/v4/cli.py @@ -79,7 +79,7 @@ class GitlabCLI: # If we don't delete it then it will be added to the URL as a query-string del self.args[key] - def __call__(self) -> Any: + def run(self) -> Any: # Check for a method that matches object + action method = f"do_{self.what}_{self.action}" if hasattr(self, method): @@ -505,7 +505,7 @@ def run( fields: List[str], ) -> None: g_cli = GitlabCLI(gl=gl, what=what, action=action, args=args) - data = g_cli() + data = g_cli.run() printer: Union[JSONPrinter, LegacyPrinter, YAMLPrinter] = PRINTERS[output]() |