From a315bee758a4c6bbddafb23531567c4ca0218b87 Mon Sep 17 00:00:00 2001
From: Adar Nimrod <nimrod@shore.co.il>
Date: Sat, 15 May 2021 00:08:49 +0300
Subject: [PATCH] Stricter return code checks.

---
 src/gitlab.py       | 4 ++--
 src/kodi.py         | 2 +-
 src/nextcloud.py    | 4 ++--
 src/notify.py       | 2 +-
 src/registry.py     | 2 +-
 src/transmission.py | 2 +-
 src/vouch.py        | 2 +-
 src/www.py          | 6 +++---
 8 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/src/gitlab.py b/src/gitlab.py
index d66593c..c872a31 100644
--- a/src/gitlab.py
+++ b/src/gitlab.py
@@ -1,8 +1,8 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://git.shore.co.il/", "codes": [301, 302]},
-    {"url": "https://git.shore.co.il/", "codes": [301, 302]},
+    {"url": "http://git.shore.co.il/", "codes": [301]},
+    {"url": "https://git.shore.co.il/", "codes": [302]},
     {"url": "https://git.shore.co.il/explore/"},
 ]
 
diff --git a/src/kodi.py b/src/kodi.py
index bbf3809..df903c2 100644
--- a/src/kodi.py
+++ b/src/kodi.py
@@ -1,7 +1,7 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://kodi.shore.co.il/", "codes": [301, 302]},
+    {"url": "http://kodi.shore.co.il/", "codes": [301]},
     {"url": "https://kodi.shore.co.il/", "codes": [401]},
 ]
 
diff --git a/src/nextcloud.py b/src/nextcloud.py
index abbf403..c5d29a8 100644
--- a/src/nextcloud.py
+++ b/src/nextcloud.py
@@ -1,8 +1,8 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://nextcloud.shore.co.il/", "codes": [301, 302]},
-    {"url": "https://nextcloud.shore.co.il/", "codes": [301, 302]},
+    {"url": "http://nextcloud.shore.co.il/", "codes": [301]},
+    {"url": "https://nextcloud.shore.co.il/", "codes": [302]},
     {"url": "https://nextcloud.shore.co.il/login"},
 ]
 
diff --git a/src/notify.py b/src/notify.py
index 86c7092..ffdfcde 100644
--- a/src/notify.py
+++ b/src/notify.py
@@ -1,7 +1,7 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://notify.shore.co.il/", "codes": [301, 302]},
+    {"url": "http://notify.shore.co.il/", "codes": [301]},
     {"url": "https://notify.shore.co.il/ping"},
 ]
 
diff --git a/src/registry.py b/src/registry.py
index fb66094..5926620 100644
--- a/src/registry.py
+++ b/src/registry.py
@@ -1,7 +1,7 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://registry.shore.co.il/", "codes": [301, 302]},
+    {"url": "http://registry.shore.co.il/", "codes": [301]},
     {"url": "https://registry.shore.co.il/"},
     {"url": "https://registry.shore.co.il/v2/_catalog"},
 ]
diff --git a/src/transmission.py b/src/transmission.py
index 5467d1d..3d53e3d 100644
--- a/src/transmission.py
+++ b/src/transmission.py
@@ -1,7 +1,7 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://transmission.shore.co.il/", "codes": [301, 302]},
+    {"url": "http://transmission.shore.co.il/", "codes": [301]},
     {"url": "https://transmission.shore.co.il/", "codes": [401]},
 ]
 
diff --git a/src/vouch.py b/src/vouch.py
index 55ffac0..e689a0f 100644
--- a/src/vouch.py
+++ b/src/vouch.py
@@ -1,7 +1,7 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://vouch.shore.co.il/", "codes": [301, 302]},
+    {"url": "http://vouch.shore.co.il/", "codes": [301]},
     {"url": "https://vouch.shore.co.il/validate", "codes": [401]},
 ]
 
diff --git a/src/www.py b/src/www.py
index efd55da..e675d73 100644
--- a/src/www.py
+++ b/src/www.py
@@ -1,9 +1,9 @@
 from utils import website_handler
 
 URLS = [
-    {"url": "http://shore.co.il/", "codes": [301, 302]},
-    {"url": "http://www.shore.co.il/", "codes": [301, 302]},
-    {"url": "https://shore.co.il/", "codes": [301, 302]},
+    {"url": "http://shore.co.il/", "codes": [301]},
+    {"url": "http://www.shore.co.il/", "codes": [301]},
+    {"url": "https://shore.co.il/", "codes": [301]},
     {"url": "https://www.shore.co.il/blog"},
 ]
 
-- 
GitLab