From 7572b01e09c11e1a2d4db52c1053d8aef0423830 Mon Sep 17 00:00:00 2001 From: Opeyemi Date: Wed, 11 Dec 2024 19:33:04 +0000 Subject: [PATCH] Update src/bitwarden_workflow_linter/actions.py Co-authored-by: Andy Pixley <3723676+pixman20@users.noreply.github.com> --- src/bitwarden_workflow_linter/actions.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/bitwarden_workflow_linter/actions.py b/src/bitwarden_workflow_linter/actions.py index 9486820..2dbb77c 100644 --- a/src/bitwarden_workflow_linter/actions.py +++ b/src/bitwarden_workflow_linter/actions.py @@ -144,9 +144,7 @@ def get_latest_version(self, action: Action) -> Action | None: if response is None or response.status != 200: return None - if json.loads(response.data)["object"]["type"] == "commit": - sha = json.loads(response.data)["object"]["sha"] - else: + if json.loads(response.data)["object"]["type"] != "commit": url = json.loads(response.data)["object"]["url"] # Follow the URL and get the commit sha for tags response = self.get_github_api_response(url, action.name)