From 3fed7d26143a008299b32ef1e6fdb17892f11b5e Mon Sep 17 00:00:00 2001 From: derrod Date: Thu, 30 Dec 2021 17:42:18 +0100 Subject: [PATCH] [api] Treat timeout <= 0 as no timeout --- legendary/api/egs.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/legendary/api/egs.py b/legendary/api/egs.py index 8b724c9..158eaaa 100644 --- a/legendary/api/egs.py +++ b/legendary/api/egs.py @@ -47,7 +47,11 @@ class EPCAPI: self.language_code = lc self.country_code = cc - self.request_timeout = timeout + + if timeout > 0: + self.request_timeout = timeout + else: + self.request_timeout = None def update_egs_params(self, egs_params): # update user-agent