Skip to content

Commit

Permalink
fet: remove unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
mckadesorensen committed Jan 8, 2025
1 parent 391bae8 commit bdf161d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
7 changes: 0 additions & 7 deletions tests/test_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -736,13 +736,6 @@ def test_try_download_from_bucket_invalid_range(
mock_check_in_region_request.assert_called_once()


@mock.patch(f"{MODULE}.JWT_COOKIE_NAME", "asf-cookie")
def test_get_jwt_field():
assert app.get_jwt_field({"asf-cookie": {"foo": "bar"}}, "foo") == "bar"
assert app.get_jwt_field({"asf-cookie": {}}, "foo") is None
assert app.get_jwt_field({}, "foo") is None


@mock.patch(f"{MODULE}.get_urs_url", autospec=True)
def test_root(mock_get_urs_url, mock_retrieve_secret, mock_make_html_response, client):
del mock_retrieve_secret
Expand Down
5 changes: 0 additions & 5 deletions thin_egress_app/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -746,11 +746,6 @@ def try_download_from_bucket(bucket, filename, user_profile, headers: dict, api_
return make_html_response(template_vars, headers, 404, "error.html")


@with_trace()
def get_jwt_field(cookievar: dict, fieldname: str):
return cookievar.get(JWT_COOKIE_NAME, {}).get(fieldname, None)


@app.route("/")
@with_trace(context={})
def root():
Expand Down

0 comments on commit bdf161d

Please sign in to comment.