switch to middleware validation
This commit is contained in:
@ -15,9 +15,10 @@ def send_post_request(uri, data, token):
|
||||
"Content-Type": "application/json",
|
||||
}
|
||||
try:
|
||||
requests.post(uri, json=data, timeout=1, headers=headers)
|
||||
response = requests.post(uri, json=data, timeout=1, headers=headers)
|
||||
print("Return code: " + str(response.status_code))
|
||||
except requests.exceptions.RequestException as e:
|
||||
pass
|
||||
print(e)
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(
|
||||
|
Reference in New Issue
Block a user