summaryrefslogtreecommitdiffstats
path: root/ogcp/views.py
diff options
context:
space:
mode:
Diffstat (limited to 'ogcp/views.py')
-rw-r--r--ogcp/views.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/ogcp/views.py b/ogcp/views.py
index 2dbe342..42dd160 100644
--- a/ogcp/views.py
+++ b/ogcp/views.py
@@ -120,8 +120,16 @@ def parse_elements(checkboxes_dict):
return elements
def get_client_setup(ip):
- payload = {'client': [ip]}
server = get_server_from_clients([ip])
+
+ payload = {'clients': [ip]}
+ r = server.post('/refresh', payload)
+ if not r:
+ raise ServerError
+ if r.status_code != requests.codes.ok:
+ raise ServerErrorCode
+
+ payload = {'client': [ip]}
r = server.get('/client/setup', payload)
if not r:
raise ServerError