summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJavier Sánchez Parra <jsanchez@soleta.eu>2022-09-09 09:28:10 +0200
committerJavier Sánchez Parra <jsanchez@soleta.eu>2022-09-27 09:48:36 +0200
commit1db12230f94c33c8d701f4af5ea3fd48e76c4dad (patch)
tree9ca73588a3b40e33cda787b419cf4ef549ffd627
parentd74ad9336ecd3dea3728b9cbbc611e1c56404e28 (diff)
Adapt Delete clients to work with several ogServers
This commit makes Delete clients view to use "get_server_from_clients()" function to send the deletion request to the correct ogServer.
-rw-r--r--ogcp/views.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/ogcp/views.py b/ogcp/views.py
index 84bf0e1..dc2a3c2 100644
--- a/ogcp/views.py
+++ b/ogcp/views.py
@@ -983,7 +983,8 @@ def action_client_delete():
return redirect(url_for('scopes'))
payload = {'clients': ips}
- r = g.server.post('/client/delete', payload)
+ server = get_server_from_clients(ips)
+ r = server.post('/client/delete', payload)
if r.status_code != requests.codes.ok:
flash(_('ogServer: error deleting client'),
category='error')