summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlejandro Sirgo Rica <asirgo@soleta.eu>2024-02-29 11:26:10 +0100
committerAlejandro Sirgo Rica <asirgo@soleta.eu>2024-02-29 11:26:10 +0100
commit48f596436c06ddb36329ec7422259dbbb5fb27bc (patch)
tree63202e10fa63ebb506697384b1f3d13340757a06
parent9be4de87b7ba14adc6754f408d855b960ffeca25 (diff)
remove duplicated parse_args in repo.py and server.py
Remove the line 'parsed_args = parser.parse_args(args)' parsing the command line arguments a second time when it is not needed.
-rw-r--r--cli/objects/repo.py1
-rw-r--r--cli/objects/server.py1
2 files changed, 0 insertions, 2 deletions
diff --git a/cli/objects/repo.py b/cli/objects/repo.py
index c287926..a85f7a3 100644
--- a/cli/objects/repo.py
+++ b/cli/objects/repo.py
@@ -88,6 +88,5 @@ class OgRepo():
print('No valid clients specified.')
return
- parsed_args = parser.parse_args(args)
payload = {'id': parsed_args.id, 'clients': list(ips)}
rest.post('/client/repo', payload=payload)
diff --git a/cli/objects/server.py b/cli/objects/server.py
index 38cc6b0..a564f59 100644
--- a/cli/objects/server.py
+++ b/cli/objects/server.py
@@ -74,6 +74,5 @@ class OgServer():
print('No clients specified.')
return
- parsed_args = parser.parse_args(args)
payload = {'id': parsed_args.id, 'clients': list(ips)}
rest.post('/client/server', payload=payload)