From 687125af5952a0e1f23035132554646cb37da1fa Mon Sep 17 00:00:00 2001 From: igna <88955484+nekospara@users.noreply.github.com> Date: Sat, 4 Sep 2021 05:53:27 -0400 Subject: [PATCH] ye --- main.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/main.py b/main.py index 6d768d7..94989fe 100644 --- a/main.py +++ b/main.py @@ -4,9 +4,13 @@ url = os.environ['URL'] amount = os.environ['AMOUNT'] def thread(): - sent = 0 - while True: - requests.get(url) + while True: + sent = 0 + r = requests.get(url) + if r.status_code == 403: + print('Invalid URL') + else: + pass sent += 1 print(f'Views sent: %s' % sent)