From 715cd279e6499776d5247b5ed71a357487623ec1 Mon Sep 17 00:00:00 2001 From: McCloudS <64094529+McCloudS@users.noreply.github.com> Date: Wed, 25 Oct 2023 23:59:20 -0600 Subject: [PATCH] Update subgen.py Fixed UnboundLocalError: cannot access local variable 'jellyfin_userid' where it is not associated with a value --- subgen/subgen.py | 1 + 1 file changed, 1 insertion(+) diff --git a/subgen/subgen.py b/subgen/subgen.py index 4031a13..5772404 100644 --- a/subgen/subgen.py +++ b/subgen/subgen.py @@ -280,6 +280,7 @@ def get_jellyfin_file_name(item_id: str, jellyfin_url: str, jellyfin_token: str) } # Cheap way to get the admin user id, and save it for later use. + global jellyfin_userid if not jellyfin_userid: users_request = json.loads(requests.get(f"{jellyfin_url}/Users", headers=headers).content) for user in users_request: