Skip to content

Commit

Permalink
Resolve SonarCloud complain: Remove unused parameter token
Browse files Browse the repository at this point in the history
  • Loading branch information
juhoinkinen committed Sep 30, 2024
1 parent e2e6ff7 commit 4dfa2d1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions annif/hfh_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def check_is_download_allowed(trust_repo, repo_id, token):
f'Download allowed from "{repo_id}" because "--trust-repo" flag is used.'
)
return
if _is_repo_in_cache(repo_id, token):
if _is_repo_in_cache(repo_id):
logger.debug(
f'Download allowed from "{repo_id}" because repo is already in cache.'
)
Expand All @@ -42,7 +42,7 @@ def check_is_download_allowed(trust_repo, repo_id, token):
)


def _is_repo_in_cache(repo_id, token):
def _is_repo_in_cache(repo_id):
from huggingface_hub import CacheNotFound, scan_cache_dir

Check warning on line 46 in annif/hfh_util.py

View check run for this annotation

Codecov / codecov/patch

annif/hfh_util.py#L46

Added line #L46 was not covered by tests

try:
Expand Down

0 comments on commit 4dfa2d1

Please sign in to comment.