From 49a50a0eddb3cb1a9f6ca00ab5a4301200fea6f7 Mon Sep 17 00:00:00 2001 From: Scott Wallace Date: Sat, 9 Sep 2023 15:55:07 +0100 Subject: [PATCH] Return the remote error, if there's an error --- main.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/main.py b/main.py index 8e5cbcb..92b3fc3 100644 --- a/main.py +++ b/main.py @@ -28,6 +28,9 @@ def process() -> Response: hours = int(request.args.get("hours", "0")) mins = int(request.args.get("mins", "0")) + if orig.status_code != 200: + return Response(orig.text, headers=orig.headers, status=orig.status_code) + orig_cal = Calendar.from_ical(orig.text) cal = Calendar()