Skip to content

Commit 20e1a75

Browse files
committed
R1720: Unnecessary "elif" after "raise" (no-else-raise)
1 parent 559a61b commit 20e1a75

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

00-Starter-Seed/server.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,10 @@ def get_token_auth_header():
5151
"description":
5252
"Authorization header must start with"
5353
" Bearer"}, 401)
54-
elif len(parts) == 1:
54+
if len(parts) == 1:
5555
raise AuthError({"code": "invalid_header",
5656
"description": "Token not found"}, 401)
57-
elif len(parts) > 2:
57+
if len(parts) > 2:
5858
raise AuthError({"code": "invalid_header",
5959
"description":
6060
"Authorization header must be"

0 commit comments

Comments
 (0)